]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
cleanup: Use new indentation style for object literals
authorFlorian Müllner <fmuellner@gnome.org>
Sun, 29 Mar 2020 21:51:13 +0000 (23:51 +0200)
committerMarge Bot <marge-bot@gnome.org>
Wed, 23 Feb 2022 12:23:52 +0000 (12:23 +0000)
We have made good progress on object literals as well, although there
are still a lot that use the old style, given how ubiquitous object
literals are.

But the needed reindentation isn't overly intrusive, as changes are
limited to the object literals themselves (i.e. they don't affect
surrounding code).

And given that object literals account for quite a bit of the remaining
differences between regular and legacy rules, doing the transition now
is still worthwhile.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2200>

70 files changed:
js/gdm/authPrompt.js
js/gdm/loginDialog.js
js/gdm/oVirt.js
js/gdm/util.js
js/gdm/vmware.js
js/misc/history.js
js/misc/objectManager.js
js/misc/smartcardManager.js
js/misc/util.js
js/perf/core.js
js/perf/hwtest.js
js/portalHelper/main.js
js/ui/accessDialog.js
js/ui/altTab.js
js/ui/appDisplay.js
js/ui/audioDeviceSelection.js
js/ui/background.js
js/ui/closeDialog.js
js/ui/components/automountManager.js
js/ui/components/autorunManager.js
js/ui/components/networkAgent.js
js/ui/components/polkitAgent.js
js/ui/components/telepathyClient.js
js/ui/ctrlAltTab.js
js/ui/dash.js
js/ui/dateMenu.js
js/ui/endSessionDialog.js
js/ui/environment.js
js/ui/grabHelper.js
js/ui/ibusCandidatePopup.js
js/ui/inhibitShortcutsDialog.js
js/ui/kbdA11yDialog.js
js/ui/keyboard.js
js/ui/layout.js
js/ui/lookingGlass.js
js/ui/magnifier.js
js/ui/main.js
js/ui/messageList.js
js/ui/messageTray.js
js/ui/modalDialog.js
js/ui/notificationDaemon.js
js/ui/osdMonitorLabeler.js
js/ui/overview.js
js/ui/padOsd.js
js/ui/pageIndicators.js
js/ui/panel.js
js/ui/popupMenu.js
js/ui/remoteSearch.js
js/ui/ripples.js
js/ui/screenShield.js
js/ui/screenshot.js
js/ui/scripting.js
js/ui/search.js
js/ui/shellDBus.js
js/ui/status/brightness.js
js/ui/status/dwellClick.js
js/ui/status/keyboard.js
js/ui/status/location.js
js/ui/status/network.js
js/ui/switchMonitor.js
js/ui/switcherPopup.js
js/ui/unlockDialog.js
js/ui/userWidget.js
js/ui/welcomeDialog.js
js/ui/windowManager.js
js/ui/windowPreview.js
js/ui/workspace.js
js/ui/workspaceThumbnail.js
js/ui/xdndHandler.js
lint/eslintrc-legacy.yml

index 01ece6bd0572d7e9f51e1ff810bc4dbb2958557c..f9673468fa7cbb4b63228d475b3eed88e0c52548 100644 (file)
@@ -653,8 +653,10 @@ var AuthPrompt = GObject.registerClass({
     }
 
     begin(params) {
-        params = Params.parse(params, { userName: null,
-                                        hold: null });
+        params = Params.parse(params, {
+            userName: null,
+            hold: null,
+        });
 
         this.updateSensitivity(false);
 
index f114e86eac306e1e7e356af3759d17e005b048f3..3bde6fb06ee15561da72b72c9df17990ec0fe787 100644 (file)
  * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
-const { AccountsService, Atk, Clutter, Gdm, Gio,
-        GLib, GObject, Meta, Pango, Shell, St } = imports.gi;
+const {
+    AccountsService, Atk, Clutter, Gdm, Gio,
+    GLib, GObject, Meta, Pango, Shell, St,
+} = imports.gi;
 
 const AuthPrompt = imports.gdm.authPrompt;
 const Batch = imports.gdm.batch;
@@ -67,9 +69,11 @@ var UserListItem = GObject.registerClass({
         this._userWidget.bind_property('label-actor', this, 'label-actor',
                                        GObject.BindingFlags.SYNC_CREATE);
 
-        this._timedLoginIndicator = new St.Bin({ style_class: 'login-dialog-timed-login-indicator',
-                                                 scale_x: 0,
-                                                 visible: false });
+        this._timedLoginIndicator = new St.Bin({
+            style_class: 'login-dialog-timed-login-indicator',
+            scale_x: 0,
+            visible: false,
+        });
         layout.add(this._timedLoginIndicator);
 
         this._onUserChanged();
@@ -167,9 +171,11 @@ var UserList = GObject.registerClass({
         this.set_policy(St.PolicyType.NEVER,
                         St.PolicyType.AUTOMATIC);
 
-        this._box = new St.BoxLayout({ vertical: true,
-                                       style_class: 'login-dialog-user-list',
-                                       pseudo_class: 'expanded' });
+        this._box = new St.BoxLayout({
+            vertical: true,
+            style_class: 'login-dialog-user-list',
+            pseudo_class: 'expanded',
+        });
 
         this.add_actor(this._box);
         this._items = {};
@@ -438,11 +444,13 @@ var LoginDialog = GObject.registerClass({
         this._updateLogoTextureId = this._textureCache.connect('texture-file-changed',
                                                                this._updateLogoTexture.bind(this));
 
-        this._userSelectionBox = new St.BoxLayout({ style_class: 'login-dialog-user-selection-box',
-                                                    x_align: Clutter.ActorAlign.CENTER,
-                                                    y_align: Clutter.ActorAlign.CENTER,
-                                                    vertical: true,
-                                                    visible: false });
+        this._userSelectionBox = new St.BoxLayout({
+            style_class: 'login-dialog-user-selection-box',
+            x_align: Clutter.ActorAlign.CENTER,
+            y_align: Clutter.ActorAlign.CENTER,
+            vertical: true,
+            visible: false,
+        });
         this.add_child(this._userSelectionBox);
 
         this._userList = new UserList();
@@ -477,17 +485,21 @@ var LoginDialog = GObject.registerClass({
 
         this._userSelectionBox.add_child(this._notListedButton);
 
-        this._bannerView = new St.ScrollView({ style_class: 'login-dialog-banner-view',
-                                               opacity: 0,
-                                               vscrollbar_policy: St.PolicyType.AUTOMATIC,
-                                               hscrollbar_policy: St.PolicyType.NEVER });
+        this._bannerView = new St.ScrollView({
+            style_class: 'login-dialog-banner-view',
+            opacity: 0,
+            vscrollbar_policy: St.PolicyType.AUTOMATIC,
+            hscrollbar_policy: St.PolicyType.NEVER,
+        });
         this.add_child(this._bannerView);
 
         let bannerBox = new St.BoxLayout({ vertical: true });
 
         this._bannerView.add_actor(bannerBox);
-        this._bannerLabel = new St.Label({ style_class: 'login-dialog-banner',
-                                           text: '' });
+        this._bannerLabel = new St.Label({
+            style_class: 'login-dialog-banner',
+            text: '',
+        });
         this._bannerLabel.clutter_text.line_wrap = true;
         this._bannerLabel.clutter_text.ellipsize = Pango.EllipsizeMode.NONE;
         bannerBox.add_child(this._bannerLabel);
@@ -502,9 +514,11 @@ var LoginDialog = GObject.registerClass({
         this._sessionMenuButton.show();
         this.add_child(this._sessionMenuButton);
 
-        this._logoBin = new St.Widget({ style_class: 'login-dialog-logo-bin',
-                                        x_align: Clutter.ActorAlign.CENTER,
-                                        y_align: Clutter.ActorAlign.END });
+        this._logoBin = new St.Widget({
+            style_class: 'login-dialog-logo-bin',
+            x_align: Clutter.ActorAlign.CENTER,
+            y_align: Clutter.ActorAlign.END,
+        });
         this._logoBin.connect('resource-scale-changed', () => {
             this._updateLogoTexture(this._textureCache, this._logoFile);
         });
index 94a22b8237f5761b6d9dd15e62143a9a6c66c0ac..21b43b246323da86f84b28af2d1d977d1a3540f2 100644 (file)
@@ -21,12 +21,14 @@ const OVirtCredentialsInfo = Gio.DBusInterfaceInfo.new_for_xml(OVirtCredentialsI
 let _oVirtCredentialsManager = null;
 
 function OVirtCredentials() {
-    var self = new Gio.DBusProxy({ g_connection: Gio.DBus.system,
-                                   g_interface_name: OVirtCredentialsInfo.name,
-                                   g_interface_info: OVirtCredentialsInfo,
-                                   g_name: 'org.ovirt.vdsm.Credentials',
-                                   g_object_path: '/org/ovirt/vdsm/Credentials',
-                                   g_flags: Gio.DBusProxyFlags.DO_NOT_LOAD_PROPERTIES });
+    var self = new Gio.DBusProxy({
+        g_connection: Gio.DBus.system,
+        g_interface_name: OVirtCredentialsInfo.name,
+        g_interface_info: OVirtCredentialsInfo,
+        g_name: 'org.ovirt.vdsm.Credentials',
+        g_object_path: '/org/ovirt/vdsm/Credentials',
+        g_flags: Gio.DBusProxyFlags.DO_NOT_LOAD_PROPERTIES,
+    });
     self.init(null);
     return self;
 }
index 771cd18fbbb69fca56d27a5ec4f8783b1728ef72..959fd44bac17fd689d766ad7d830220cacd58280 100644 (file)
@@ -112,8 +112,10 @@ function cloneAndFadeOutActor(actor) {
     // and reveals its sibling.
     actor.hide();
 
-    let clone = new Clutter.Clone({ source: actor,
-                                    reactive: false });
+    const clone = new Clutter.Clone({
+        source: actor,
+        reactive: false,
+    });
 
     Main.uiGroup.add_child(clone);
 
index fb80a78a22c5663419f5d929a08d43b50a3ed13e..20d40743eb0f0a6d3c7d79ba8e12fec5c5dc6c00 100644 (file)
@@ -24,12 +24,14 @@ const VmwareCredentialsInfo = Gio.DBusInterfaceInfo.new_for_xml(VmwareCredential
 let _vmwareCredentialsManager = null;
 
 function VmwareCredentials() {
-    var self = new Gio.DBusProxy({ g_connection: Gio.DBus.session,
-                                   g_interface_name: VmwareCredentialsInfo.name,
-                                   g_interface_info: VmwareCredentialsInfo,
-                                   g_name: dbusInterface,
-                                   g_object_path: dbusPath,
-                                   g_flags: Gio.DBusProxyFlags.DO_NOT_LOAD_PROPERTIES });
+    var self = new Gio.DBusProxy({
+        g_connection: Gio.DBus.session,
+        g_interface_name: VmwareCredentialsInfo.name,
+        g_interface_info: VmwareCredentialsInfo,
+        g_name: dbusInterface,
+        g_object_path: dbusPath,
+        g_flags: Gio.DBusProxyFlags.DO_NOT_LOAD_PROPERTIES,
+    });
     self.init(null);
     return self;
 }
index 4152588818ae48078e026bef9b9089f90932819b..af21574ce4460ea9e0d759ac646485eadb4c0b54 100644 (file)
@@ -8,9 +8,11 @@ var DEFAULT_LIMIT = 512;
 
 var HistoryManager = class {
     constructor(params) {
-        params = Params.parse(params, { gsettingsKey: null,
-                                        limit: DEFAULT_LIMIT,
-                                        entry: null });
+        params = Params.parse(params, {
+            gsettingsKey: null,
+            limit: DEFAULT_LIMIT,
+            entry: null,
+        });
 
         this._key = params.gsettingsKey;
         this._limit = params.limit;
index 4c4e0b6e32404076f7b0a736c58808e9bef54dca..42076f21eae1f6eb20b9e2daf1bbf1f00ffb37d1 100644 (file)
@@ -27,24 +27,28 @@ const ObjectManagerInfo = Gio.DBusInterfaceInfo.new_for_xml(ObjectManagerIface);
 
 var ObjectManager = class {
     constructor(params) {
-        params = Params.parse(params, { connection: null,
-                                        name: null,
-                                        objectPath: null,
-                                        knownInterfaces: null,
-                                        cancellable: null,
-                                        onLoaded: null });
+        params = Params.parse(params, {
+            connection: null,
+            name: null,
+            objectPath: null,
+            knownInterfaces: null,
+            cancellable: null,
+            onLoaded: null,
+        });
 
         this._connection = params.connection;
         this._serviceName = params.name;
         this._managerPath = params.objectPath;
         this._cancellable = params.cancellable;
 
-        this._managerProxy = new Gio.DBusProxy({ g_connection: this._connection,
-                                                 g_interface_name: ObjectManagerInfo.name,
-                                                 g_interface_info: ObjectManagerInfo,
-                                                 g_name: this._serviceName,
-                                                 g_object_path: this._managerPath,
-                                                 g_flags: Gio.DBusProxyFlags.DO_NOT_AUTO_START });
+        this._managerProxy = new Gio.DBusProxy({
+            g_connection: this._connection,
+            g_interface_name: ObjectManagerInfo.name,
+            g_interface_info: ObjectManagerInfo,
+            g_name: this._serviceName,
+            g_object_path: this._managerPath,
+            g_flags: Gio.DBusProxyFlags.DO_NOT_AUTO_START,
+        });
 
         this._interfaceInfos = {};
         this._objects = {};
@@ -80,12 +84,14 @@ var ObjectManager = class {
             return;
         }
 
-        let proxy = new Gio.DBusProxy({ g_connection: this._connection,
-                                        g_name: this._serviceName,
-                                        g_object_path: objectPath,
-                                        g_interface_name: interfaceName,
-                                        g_interface_info: info,
-                                        g_flags: Gio.DBusProxyFlags.DO_NOT_AUTO_START });
+        const proxy = new Gio.DBusProxy({
+            g_connection: this._connection,
+            g_name: this._serviceName,
+            g_object_path: objectPath,
+            g_interface_name: interfaceName,
+            g_interface_info: info,
+            g_flags: Gio.DBusProxyFlags.DO_NOT_AUTO_START,
+        });
 
         try {
             await proxy.init_async(GLib.PRIORITY_DEFAULT, this._cancellable);
index d9b6ff47473174bbd5b14a5e0bf9e137c4d4763d..9383272386944add75befd046f7238565bf1ad68 100644 (file)
@@ -27,11 +27,13 @@ function getSmartcardManager() {
 
 var SmartcardManager = class {
     constructor() {
-        this._objectManager = new ObjectManager.ObjectManager({ connection: Gio.DBus.session,
-                                                                name: "org.gnome.SettingsDaemon.Smartcard",
-                                                                objectPath: '/org/gnome/SettingsDaemon/Smartcard',
-                                                                knownInterfaces: [SmartcardTokenIface],
-                                                                onLoaded: this._onLoaded.bind(this) });
+        this._objectManager = new ObjectManager.ObjectManager({
+            connection: Gio.DBus.session,
+            name: 'org.gnome.SettingsDaemon.Smartcard',
+            objectPath: '/org/gnome/SettingsDaemon/Smartcard',
+            knownInterfaces: [SmartcardTokenIface],
+            onLoaded: this._onLoaded.bind(this),
+        });
         this._insertedTokens = {};
         this._loginToken = null;
     }
index 389fdde28e28f3b5ef33a2ddfbe6d0dbbe548af5..8f7192f53e7876cc4ac2270efb40679a74f95706 100644 (file)
@@ -124,8 +124,10 @@ function trySpawn(argv) {
     } catch (err) {
         /* Rewrite the error in case of ENOENT */
         if (err.matches(GLib.SpawnError, GLib.SpawnError.NOENT)) {
-            throw new GLib.SpawnError({ code: GLib.SpawnError.NOENT,
-                                        message: _("Command not found") });
+            throw new GLib.SpawnError({
+                code: GLib.SpawnError.NOENT,
+                message: _('Command not found'),
+            });
         } else if (err instanceof GLib.Error) {
             // The exception from gjs contains an error string like:
             //   Error invoking GLib.spawn_command_line_async: Failed to
index f3f496b030a63f17ff93cfc9bfe1ab79c7f35fbf..bd7e220f194557d8c52d4e0dffbd5014d1e4473e 100644 (file)
@@ -16,59 +16,86 @@ const Scripting = imports.ui.scripting;
 // on a particular system.
 
 var METRICS = {
-    overviewLatencyFirst:
-    { description: "Time to first frame after triggering overview, first time",
-      units: "us" },
-    overviewFpsFirst:
-    { description: "Frame rate when going to the overview, first time",
-      units: "frames / s" },
-    overviewLatencySubsequent:
-    { description: "Time to first frame after triggering overview, second time",
-      units: "us" },
-    overviewFpsSubsequent:
-    { description: "Frames rate when going to the overview, second time",
-      units: "frames / s" },
-    overviewFps5Windows:
-    { description: "Frames rate when going to the overview, 5 windows open",
-      units: "frames / s" },
-    overviewFps10Windows:
-    { description: "Frames rate when going to the overview, 10 windows open",
-      units: "frames / s" },
-    overviewFps5Maximized:
-    { description: "Frames rate when going to the overview, 5 maximized windows open",
-      units: "frames / s" },
-    overviewFps10Maximized:
-    { description: "Frames rate when going to the overview, 10 maximized windows open",
-      units: "frames / s" },
-    overviewFps5Alpha:
-    { description: "Frames rate when going to the overview, 5 alpha-transparent windows open",
-      units: "frames / s" },
-    overviewFps10Alpha:
-    { description: "Frames rate when going to the overview, 10 alpha-transparent windows open",
-      units: "frames / s" },
-    usedAfterOverview:
-    { description: "Malloc'ed bytes after the overview is shown once",
-      units: "B" },
-    leakedAfterOverview:
-    { description: "Additional malloc'ed bytes the second time the overview is shown",
-      units: "B" },
-    applicationsShowTimeFirst:
-    { description: "Time to switch to applications view, first time",
-      units: "us" },
-    applicationsShowTimeSubsequent:
-    { description: "Time to switch to applications view, second time",
-      units: "us" },
+    overviewLatencyFirst: {
+        description: 'Time to first frame after triggering overview, first time',
+        units: 'us',
+    },
+    overviewFpsFirst: {
+        description: 'Frame rate when going to the overview, first time',
+        units: 'frames / s',
+    },
+    overviewLatencySubsequent: {
+        description: 'Time to first frame after triggering overview, second time',
+        units: 'us',
+    },
+    overviewFpsSubsequent: {
+        description: 'Frames rate when going to the overview, second time',
+        units: 'frames / s',
+    },
+    overviewFps5Windows: {
+        description: 'Frames rate when going to the overview, 5 windows open',
+        units: 'frames / s',
+    },
+    overviewFps10Windows: {
+        description: 'Frames rate when going to the overview, 10 windows open',
+        units: 'frames / s',
+    },
+    overviewFps5Maximized: {
+        description: 'Frames rate when going to the overview, 5 maximized windows open',
+        units: 'frames / s',
+    },
+    overviewFps10Maximized: {
+        description: 'Frames rate when going to the overview, 10 maximized windows open',
+        units: 'frames / s',
+    },
+    overviewFps5Alpha: {
+        description: 'Frames rate when going to the overview, 5 alpha-transparent windows open',
+        units: 'frames / s',
+    },
+    overviewFps10Alpha: {
+        description: 'Frames rate when going to the overview, 10 alpha-transparent windows open',
+        units: 'frames / s',
+    },
+    usedAfterOverview: {
+        description: "Malloc'ed bytes after the overview is shown once",
+        units: 'B',
+    },
+    leakedAfterOverview: {
+        description: "Additional malloc'ed bytes the second time the overview is shown",
+        units: 'B',
+    },
+    applicationsShowTimeFirst: {
+        description: 'Time to switch to applications view, first time',
+        units: 'us',
+    },
+    applicationsShowTimeSubsequent: {
+        description: 'Time to switch to applications view, second time',
+        units: 'us',
+    },
 };
 
-let WINDOW_CONFIGS = [
-    { width: 640, height: 480, alpha: false, maximized: false, count: 1,  metric: 'overviewFpsSubsequent' },
-    { width: 640, height: 480, alpha: false, maximized: false, count: 5,  metric: 'overviewFps5Windows'  },
-    { width: 640, height: 480, alpha: false, maximized: false, count: 10, metric: 'overviewFps10Windows'  },
-    { width: 640, height: 480, alpha: false, maximized: true,  count: 5,  metric: 'overviewFps5Maximized' },
-    { width: 640, height: 480, alpha: false, maximized: true,  count: 10, metric: 'overviewFps10Maximized' },
-    { width: 640, height: 480, alpha: true,  maximized: false, count: 5,  metric: 'overviewFps5Alpha' },
-    { width: 640, height: 480, alpha: true,  maximized: false, count: 10, metric: 'overviewFps10Alpha' },
-];
+const WINDOW_CONFIGS = [{
+    width: 640, height: 480,
+    alpha: false, maximized: false, count: 1,  metric: 'overviewFpsSubsequent',
+}, {
+    width: 640, height: 480,
+    alpha: false, maximized: false, count: 5,  metric: 'overviewFps5Windows',
+}, {
+    width: 640, height: 480,
+    alpha: false, maximized: false, count: 10, metric: 'overviewFps10Windows',
+}, {
+    width: 640, height: 480,
+    alpha: false, maximized: true,  count: 5,  metric: 'overviewFps5Maximized',
+}, {
+    width: 640, height: 480,
+    alpha: false, maximized: true,  count: 10, metric: 'overviewFps10Maximized',
+}, {
+    width: 640, height: 480,
+    alpha: true,  maximized: false, count: 5,  metric: 'overviewFps5Alpha',
+}, {
+    width: 640, height: 480,
+    alpha: true,  maximized: false, count: 10, metric: 'overviewFps10Alpha',
+}];
 
 async function run() {
     /* eslint-disable no-await-in-loop */
@@ -96,10 +123,12 @@ async function run() {
             await Scripting.destroyTestWindows();
 
             for (let k = 0; k < config.count; k++) {
-                await Scripting.createTestWindow({ width: config.width,
-                                                   height: config.height,
-                                                   alpha: config.alpha,
-                                                   maximized: config.maximized });
+                await Scripting.createTestWindow({
+                    width: config.width,
+                    height: config.height,
+                    alpha: config.alpha,
+                    maximized: config.maximized,
+                });
             }
 
             await Scripting.waitTestWindows();
index 8793ce8a9db5a91c3397ffed4c3ceb8c85389296..63777bd9d066629123e72c3e347238e8609ca6b0 100644 (file)
@@ -12,33 +12,40 @@ const Main = imports.ui.main;
 const Scripting = imports.ui.scripting;
 
 var METRICS = {
-    timeToDesktop:
-    { description: "Time from starting graphical.target to desktop showing",
-      units: "us" },
-
-    overviewShowTime:
-    { description: "Time to switch to overview view, first time",
-      units: "us" },
-
-    applicationsShowTime:
-    { description: "Time to switch to applications view, first time",
-      units: "us" },
-
-    mainViewRedrawTime:
-    { description: "Time to redraw the main view, full screen",
-      units: "us" },
-
-    overviewRedrawTime:
-    { description: "Time to redraw the overview, full screen, 5 windows",
-      units: "us" },
-
-    applicationRedrawTime:
-    { description: "Time to redraw frame with a maximized application update",
-      units: "us" },
-
-    geditStartTime:
-    { description: "Time from gedit launch to window drawn",
-      units: "us" },
+    timeToDesktop: {
+        description: 'Time from starting graphical.target to desktop showing',
+        units: 'us',
+    },
+
+    overviewShowTime: {
+        description: 'Time to switch to overview view, first time',
+        units: 'us',
+    },
+
+    applicationsShowTime: {
+        description: 'Time to switch to applications view, first time',
+        units: 'us',
+    },
+
+    mainViewRedrawTime: {
+        description: 'Time to redraw the main view, full screen',
+        units: 'us',
+    },
+
+    overviewRedrawTime: {
+        description: 'Time to redraw the overview, full screen, 5 windows',
+        units: 'us',
+    },
+
+    applicationRedrawTime: {
+        description: 'Time to redraw frame with a maximized application update',
+        units: 'us',
+    },
+
+    geditStartTime: {
+        description: 'Time from gedit launch to window drawn',
+        units: 'us',
+    },
 };
 
 function waitAndDraw(milliseconds) {
@@ -168,8 +175,10 @@ async function run() {
     await Scripting.destroyTestWindows();
     Main.overview.hide();
 
-    await Scripting.createTestWindow({ maximized: true,
-                                       redraws: true });
+    await Scripting.createTestWindow({
+        maximized: true,
+        redraws: true,
+    });
     await Scripting.waitTestWindows();
 
     await Scripting.sleep(1000);
index 9f9b987184a7cae33159689b7e1eeb269a523949..bc9958e599b31f79592e838aad4248c72785ef6d 100644 (file)
@@ -42,34 +42,44 @@ class PortalHeaderBar extends Gtk.HeaderBar {
         super._init({ show_close_button: true });
 
         // See ephy-title-box.c in epiphany for the layout
-        let vbox = new Gtk.Box({ orientation: Gtk.Orientation.VERTICAL,
-                                 spacing: 0 });
+        const vbox = new Gtk.Box({
+            orientation: Gtk.Orientation.VERTICAL,
+            spacing: 0,
+        });
         this.set_custom_title(vbox);
 
         /* TRANSLATORS: this is the title of the wifi captive portal login window */
-        let titleLabel = new Gtk.Label({ label: _("Hotspot Login"),
-                                         wrap: false,
-                                         single_line_mode: true,
-                                         ellipsize: Pango.EllipsizeMode.END });
+        const titleLabel = new Gtk.Label({
+            label: _('Hotspot Login'),
+            wrap: false,
+            single_line_mode: true,
+            ellipsize: Pango.EllipsizeMode.END,
+        });
         titleLabel.get_style_context().add_class('title');
         vbox.add(titleLabel);
 
-        let hbox = new Gtk.Box({ orientation: Gtk.Orientation.HORIZONTAL,
-                                 spacing: 4,
-                                 halign: Gtk.Align.CENTER,
-                                 valign: Gtk.Align.BASELINE });
+        const hbox = new Gtk.Box({
+            orientation: Gtk.Orientation.HORIZONTAL,
+            spacing: 4,
+            halign: Gtk.Align.CENTER,
+            valign: Gtk.Align.BASELINE,
+        });
         hbox.get_style_context().add_class('subtitle');
         vbox.add(hbox);
 
-        this._lockImage = new Gtk.Image({ icon_size: Gtk.IconSize.MENU,
-                                          valign: Gtk.Align.BASELINE });
+        this._lockImage = new Gtk.Image({
+            icon_size: Gtk.IconSize.MENU,
+            valign: Gtk.Align.BASELINE,
+        });
         hbox.add(this._lockImage);
 
-        this.subtitleLabel = new Gtk.Label({ wrap: false,
-                                             single_line_mode: true,
-                                             ellipsize: Pango.EllipsizeMode.END,
-                                             valign: Gtk.Align.BASELINE,
-                                             selectable: true });
+        this.subtitleLabel = new Gtk.Label({
+            wrap: false,
+            single_line_mode: true,
+            ellipsize: Pango.EllipsizeMode.END,
+            valign: Gtk.Align.BASELINE,
+            selectable: true,
+        });
         this.subtitleLabel.get_style_context().add_class('subtitle');
         hbox.add(this.subtitleLabel);
 
@@ -271,9 +281,11 @@ class PortalWindow extends Gtk.ApplicationWindow {
 var WebPortalHelper = GObject.registerClass(
 class WebPortalHelper extends Gtk.Application {
     _init() {
-        super._init({ application_id: 'org.gnome.Shell.PortalHelper',
-                      flags: Gio.ApplicationFlags.IS_SERVICE,
-                      inactivity_timeout: 30000 });
+        super._init({
+            application_id: 'org.gnome.Shell.PortalHelper',
+            flags: Gio.ApplicationFlags.IS_SERVICE,
+            inactivity_timeout: 30000,
+        });
 
         this._dbusImpl = Gio.DBusExportedObject.wrapJSObject(HelperDBusInterface, this);
         this._queue = [];
index 4c2aa238fae63bdb11e850dc1f3e617786ee4a2b..393315d458257461060cf7fa13cdf0c9dee7de88 100644 (file)
@@ -64,15 +64,15 @@ class AccessDialog extends ModalDialog.ModalDialog {
         });
         content.add_child(bodyLabel);
 
-        this.addButton({ label: denyLabel,
-                         action: () => {
-                             this._sendResponse(DialogResponse.CANCEL);
-                         },
-                         key: Clutter.KEY_Escape });
-        this.addButton({ label: grantLabel,
-                         action: () => {
-                             this._sendResponse(DialogResponse.OK);
-                         } });
+        this.addButton({
+            label: denyLabel,
+            action: () => this._sendResponse(DialogResponse.CANCEL),
+            key: Clutter.KEY_Escape,
+        });
+        this.addButton({
+            label: grantLabel,
+            action: () => this._sendResponse(DialogResponse.OK),
+        });
     }
 
     open() {
index adb5c96cd5e7054e40af17b7260481b3d4e0ef62..f8e79a1761e0fe270cdbcb549eb4f458fd585faa 100644 (file)
@@ -28,14 +28,16 @@ var AppIconMode = {
 function _createWindowClone(window, size) {
     let [width, height] = window.get_size();
     let scale = Math.min(1.0, size / width, size / height);
-    return new Clutter.Clone({ source: window,
-                               width: width * scale,
-                               height: height * scale,
-                               x_align: Clutter.ActorAlign.CENTER,
-                               y_align: Clutter.ActorAlign.CENTER,
-                               // usual hack for the usual bug in ClutterBinLayout...
-                               x_expand: true,
-                               y_expand: true });
+    return new Clutter.Clone({
+        source: window,
+        width: width * scale,
+        height: height * scale,
+        x_align: Clutter.ActorAlign.CENTER,
+        y_align: Clutter.ActorAlign.CENTER,
+        // usual hack for the usual bug in ClutterBinLayout...
+        x_expand: true,
+        y_expand: true,
+    });
 }
 
 function getWindows(workspace) {
@@ -462,10 +464,12 @@ class CyclerHighlight extends St.Widget {
 // We don't show an actual popup, so just provide what SwitcherPopup
 // expects instead of inheriting from SwitcherList
 var CyclerList = GObject.registerClass({
-    Signals: { 'item-activated': { param_types: [GObject.TYPE_INT] },
-               'item-entered': { param_types: [GObject.TYPE_INT] },
-               'item-removed': { param_types: [GObject.TYPE_INT] },
-               'item-highlighted': { param_types: [GObject.TYPE_INT] } },
+    Signals: {
+        'item-activated': { param_types: [GObject.TYPE_INT] },
+        'item-entered': { param_types: [GObject.TYPE_INT] },
+        'item-removed': { param_types: [GObject.TYPE_INT] },
+        'item-highlighted': { param_types: [GObject.TYPE_INT] },
+    },
 }, class CyclerList extends St.Widget {
     highlight(index, _justOutline) {
         this.emit('item-highlighted', index);
@@ -653,8 +657,10 @@ class WindowCyclerPopup extends CyclerPopup {
 var AppIcon = GObject.registerClass(
 class AppIcon extends St.BoxLayout {
     _init(app) {
-        super._init({ style_class: 'alt-tab-app',
-                      vertical: true });
+        super._init({
+            style_class: 'alt-tab-app',
+            vertical: true,
+        });
 
         this.app = app;
         this.icon = null;
@@ -904,8 +910,10 @@ class ThumbnailSwitcher extends SwitcherPopup.SwitcherList {
         this._windows = windows;
 
         for (let i = 0; i < windows.length; i++) {
-            let box = new St.BoxLayout({ style_class: 'thumbnail-box',
-                                         vertical: true });
+            const box = new St.BoxLayout({
+                style_class: 'thumbnail-box',
+                vertical: true,
+            });
 
             let bin = new St.Bin({ style_class: 'thumbnail' });
 
@@ -991,8 +999,10 @@ class ThumbnailSwitcher extends SwitcherPopup.SwitcherList {
 var WindowIcon = GObject.registerClass(
 class WindowIcon extends St.BoxLayout {
     _init(window, mode) {
-        super._init({ style_class: 'alt-tab-app',
-                      vertical: true });
+        super._init({
+            style_class: 'alt-tab-app',
+            vertical: true,
+        });
 
         this.window = window;
 
@@ -1051,8 +1061,10 @@ class WindowSwitcher extends SwitcherPopup.SwitcherList {
     _init(windows, mode) {
         super._init(true);
 
-        this._label = new St.Label({ x_align: Clutter.ActorAlign.CENTER,
-                                     y_align: Clutter.ActorAlign.CENTER });
+        this._label = new St.Label({
+            x_align: Clutter.ActorAlign.CENTER,
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this.add_actor(this._label);
 
         this.windows = windows;
index 95bba64020f9cd8e41c169816cc0544ebd50a652..9abadaabec2649124f7ad18815c17ebd6aa91444 100644 (file)
@@ -2352,8 +2352,10 @@ var FolderIcon = GObject.registerClass({
         this._name = '';
         this._parentView = parentView;
 
-        this._folder = new Gio.Settings({ schema_id: 'org.gnome.desktop.app-folders.folder',
-                                          path });
+        this._folder = new Gio.Settings({
+            schema_id: 'org.gnome.desktop.app-folders.folder',
+            path,
+        });
 
         this.icon = new IconGrid.BaseIcon('', {
             createIcon: this._createIcon.bind(this),
@@ -3023,8 +3025,11 @@ var AppIcon = GObject.registerClass({
         this._id = app.get_id();
         this._name = app.get_name();
 
-        this._iconContainer = new St.Widget({ layout_manager: new Clutter.BinLayout(),
-                                              x_expand: true, y_expand: true });
+        this._iconContainer = new St.Widget({
+            layout_manager: new Clutter.BinLayout(),
+            x_expand: true,
+            y_expand: true,
+        });
 
         this.set_child(this._iconContainer);
 
@@ -3221,8 +3226,10 @@ var AppIcon = GObject.registerClass({
         let { stack } = new Error();
         log(`shellWorkspaceLaunch is deprecated, use app.open_new_window() instead\n${stack}`);
 
-        params = Params.parse(params, { workspace: -1,
-                                        timestamp: 0 });
+        params = Params.parse(params, {
+            workspace: -1,
+            timestamp: 0,
+        });
 
         this.app.open_new_window(params.workspace);
     }
index fb78b79225ae50b4507fb313ed54cdfffff416cc..e284772e6e69538a4d379e530c94322869be4818 100644 (file)
@@ -90,8 +90,10 @@ var AudioDeviceSelectionDialog = GObject.registerClass({
     }
 
     _addDevice(device) {
-        let box = new St.BoxLayout({ style_class: 'audio-selection-device-box',
-                                     vertical: true });
+        const box = new St.BoxLayout({
+            style_class: 'audio-selection-device-box',
+            vertical: true,
+        });
         box.connect('notify::height', () => {
             Meta.later_add(Meta.LaterType.BEFORE_REDRAW, () => {
                 box.width = box.height;
@@ -99,18 +101,24 @@ var AudioDeviceSelectionDialog = GObject.registerClass({
             });
         });
 
-        let icon = new St.Icon({ style_class: 'audio-selection-device-icon',
-                                 icon_name: this._getDeviceIcon(device) });
+        const icon = new St.Icon({
+            style_class: 'audio-selection-device-icon',
+            icon_name: this._getDeviceIcon(device),
+        });
         box.add(icon);
 
-        let label = new St.Label({ style_class: 'audio-selection-device-label',
-                                   text: this._getDeviceLabel(device),
-                                   x_align: Clutter.ActorAlign.CENTER });
+        const label = new St.Label({
+            style_class: 'audio-selection-device-label',
+            text: this._getDeviceLabel(device),
+            x_align: Clutter.ActorAlign.CENTER,
+        });
         box.add(label);
 
-        let button = new St.Button({ style_class: 'audio-selection-device',
-                                     can_focus: true,
-                                     child: box });
+        const button = new St.Button({
+            style_class: 'audio-selection-device',
+            can_focus: true,
+            child: box,
+        });
         this._selectionBox.add(button);
 
         button.connect('clicked', () => {
index 0b53f3fd0517886c10a7cb0cebe473de4a18c4ea..1b77043b9a459221c92584184b6c405df489f5d4 100644 (file)
@@ -163,9 +163,11 @@ var BackgroundCache = class BackgroundCache {
     }
 
     getAnimation(params) {
-        params = Params.parse(params, { file: null,
-                                        settingsSchema: null,
-                                        onLoaded: null });
+        params = Params.parse(params, {
+            file: null,
+            settingsSchema: null,
+            onLoaded: null,
+        });
 
         let animation = this._animations[params.settingsSchema];
         if (animation && _fileEqual0(animation.file, params.file)) {
index 63a0bcfcf8d9b14d97dccda9b7b9f11649048838..317d775933911bad1bf166169270813a540c3072 100644 (file)
@@ -67,12 +67,16 @@ var CloseDialog = GObject.registerClass({
         this._dialog.height = windowActor.height;
 
         this._dialog.contentLayout.add_child(this._createDialogContent());
-        this._dialog.addButton({ label: _('Force Quit'),
-                                 action: this._onClose.bind(this),
-                                 default: true });
-        this._dialog.addButton({ label: _('Wait'),
-                                 action: this._onWait.bind(this),
-                                 key: Clutter.KEY_Escape });
+        this._dialog.addButton({
+            label: _('Force Quit'),
+            action: this._onClose.bind(this),
+            default: true,
+        });
+        this._dialog.addButton({
+            label: _('Wait'),
+            action: this._onWait.bind(this),
+            key: Clutter.KEY_Escape,
+        });
 
         global.focus_manager.add_group(this._dialog);
 
index 86c3a824e361c856366e1311d65e412e5cf281d6..762e2befc01b1d2dd703454c8f753d2d23c5640c 100644 (file)
@@ -65,9 +65,11 @@ var AutomountManager = class {
     _startupMountAll() {
         let volumes = this._volumeMonitor.get_volumes();
         volumes.forEach(volume => {
-            this._checkAndMountVolume(volume, { checkSession: false,
-                                                useMountOp: false,
-                                                allowAutorun: false });
+            this._checkAndMountVolume(volume, {
+                checkSession: false,
+                useMountOp: false,
+                allowAutorun: false,
+            });
         });
 
         this._mountAllId = 0;
@@ -132,9 +134,11 @@ var AutomountManager = class {
     }
 
     _checkAndMountVolume(volume, params) {
-        params = Params.parse(params, { checkSession: true,
-                                        useMountOp: true,
-                                        allowAutorun: true });
+        params = Params.parse(params, {
+            checkSession: true,
+            useMountOp: true,
+            allowAutorun: true,
+        });
 
         if (params.checkSession) {
             // if we're not in the current ConsoleKit session,
index f26a2e5f7517e4ba1c55fec2de559a756c8e1722..df7cd4221246910bb0385c6fd463101126bb4fdb 100644 (file)
@@ -323,8 +323,10 @@ class AutorunNotification extends MessageTray.Notification {
             x_expand: true,
             x_align: Clutter.ActorAlign.START,
         });
-        let icon = new St.Icon({ gicon: app.get_icon(),
-                                 style_class: 'hotplug-notification-item-icon' });
+        const icon = new St.Icon({
+            gicon: app.get_icon(),
+            style_class: 'hotplug-notification-item-icon',
+        });
         box.add(icon);
 
         let label = new St.Bin({
@@ -335,10 +337,12 @@ class AutorunNotification extends MessageTray.Notification {
         });
         box.add(label);
 
-        let button = new St.Button({ child: box,
-                                     x_expand: true,
-                                     button_mask: St.ButtonMask.ONE,
-                                     style_class: 'hotplug-notification-item button' });
+        const button = new St.Button({
+            child: box,
+            x_expand: true,
+            button_mask: St.ButtonMask.ONE,
+            style_class: 'hotplug-notification-item button',
+        });
 
         button.connect('clicked', () => {
             startAppForMount(app, this._mount);
index 82ed97890bafa55fc4770d1daa6e28bbf97993a2..532924ce5cd47f663ce40547523dd6825a533667 100644 (file)
@@ -598,9 +598,11 @@ var VPNRequestHandler = class {
             if (keyfile.get_integer(VPN_UI_GROUP, 'Version') != 2)
                 throw new Error('Invalid plugin keyfile version, is %d');
 
-            contentOverride = { title: keyfile.get_string(VPN_UI_GROUP, 'Title'),
-                                message: keyfile.get_string(VPN_UI_GROUP, 'Description'),
-                                secrets: [] };
+            contentOverride = {
+                title: keyfile.get_string(VPN_UI_GROUP, 'Title'),
+                message: keyfile.get_string(VPN_UI_GROUP, 'Description'),
+                secrets: [],
+            };
 
             let [groups, len_] = keyfile.get_groups();
             for (let i = 0; i < groups.length; i++) {
index eda2e237c1f98d4190da12d5d1e7fabd96b681a1..4f416c27c5f693d4daa030603f754eef03133016 100644 (file)
@@ -1,8 +1,10 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 /* exported Component */
 
-const { AccountsService, Clutter, GLib,
-        GObject, Pango, PolkitAgent, Polkit, Shell, St } = imports.gi;
+const {
+    AccountsService, Clutter, GLib, GObject,
+    Pango, PolkitAgent, Polkit, Shell, St,
+} = imports.gi;
 
 const Dialog = imports.ui.dialog;
 const Main = imports.ui.main;
@@ -135,12 +137,16 @@ var AuthenticationDialog = GObject.registerClass({
         passwordBox.add_child(warningBox);
         bodyContent.add_child(passwordBox);
 
-        this._cancelButton = this.addButton({ label: _("Cancel"),
-                                              action: this.cancel.bind(this),
-                                              key: Clutter.KEY_Escape });
-        this._okButton = this.addButton({ label: _("Authenticate"),
-                                          action: this._onAuthenticateButtonPressed.bind(this),
-                                          reactive: false });
+        this._cancelButton = this.addButton({
+            label: _('Cancel'),
+            action: this.cancel.bind(this),
+            key: Clutter.KEY_Escape,
+        });
+        this._okButton = this.addButton({
+            label: _('Authenticate'),
+            action: this._onAuthenticateButtonPressed.bind(this),
+            reactive: false,
+        });
         this._okButton.bind_property('reactive',
             this._okButton, 'can-focus',
             GObject.BindingFlags.SYNC_CREATE);
@@ -168,8 +174,10 @@ var AuthenticationDialog = GObject.registerClass({
     _initiateSession() {
         this._destroySession(DELAYED_RESET_TIMEOUT);
 
-        this._session = new PolkitAgent.Session({ identity: this._identityToAuth,
-                                                  cookie: this._cookie });
+        this._session = new PolkitAgent.Session({
+            identity: this._identityToAuth,
+            cookie: this._cookie,
+        });
         this._sessionCompletedId = this._session.connect('completed', this._onSessionCompleted.bind(this));
         this._sessionRequestId = this._session.connect('request', this._onSessionRequest.bind(this));
         this._sessionShowErrorId = this._session.connect('show-error', this._onSessionShowError.bind(this));
index e0719a465a8fb3dcdce49bd99f59980de24a4f35..1252654fe38974ee81443b8373afc9ea05a94f3b 100644 (file)
@@ -156,9 +156,11 @@ class TelepathyClient extends Tp.BaseClient {
         // channel matching its filters is detected.
         // The second argument, recover, means _observeChannels will be run
         // for any existing channel as well.
-        super._init({ name: 'GnomeShell',
-                      account_manager: this._accountManager,
-                      uniquify_name: true });
+        super._init({
+            name: 'GnomeShell',
+            account_manager: this._accountManager,
+            uniquify_name: true,
+        });
 
         // We only care about single-user text-based chats
         let filter = {};
@@ -255,16 +257,20 @@ class TelepathyClient extends Tp.BaseClient {
         let chanType = channel.get_channel_type();
 
         if (channel.get_invalidated()) {
-            context.fail(new Tp.Error({ code: Tp.Error.INVALID_ARGUMENT,
-                                        message: 'Channel is invalidated' }));
+            context.fail(new Tp.Error({
+                code: Tp.Error.INVALID_ARGUMENT,
+                message: 'Channel is invalidated',
+            }));
             return;
         }
 
         if (chanType == Tp.IFACE_CHANNEL_TYPE_TEXT) {
             this._approveTextChannel(account, conn, channel, dispatchOp, context);
         } else {
-            context.fail(new Tp.Error({ code: Tp.Error.INVALID_ARGUMENT,
-                                        message: 'Unsupported channel type' }));
+            context.fail(new Tp.Error({
+                code: Tp.Error.INVALID_ARGUMENT,
+                message: 'Unsupported channel type',
+            }));
         }
     }
 
@@ -272,8 +278,10 @@ class TelepathyClient extends Tp.BaseClient {
         let [targetHandle_, targetHandleType] = channel.get_handle();
 
         if (targetHandleType != Tp.HandleType.CONTACT) {
-            context.fail(new Tp.Error({ code: Tp.Error.INVALID_ARGUMENT,
-                                        message: 'Unsupported handle type' }));
+            context.fail(new Tp.Error({
+                code: Tp.Error.INVALID_ARGUMENT,
+                message: 'Unsupported handle type',
+            }));
             return;
         }
 
@@ -709,19 +717,22 @@ var ChatNotification = HAVE_TP ? GObject.registerClass({
         }
 
         if (message.direction == NotificationDirection.RECEIVED) {
-            this.update(this.source.title, messageBody,
-                        { datetime: GLib.DateTime.new_from_unix_local(message.timestamp),
-                          bannerMarkup: true });
+            this.update(this.source.title, messageBody, {
+                datetime: GLib.DateTime.new_from_unix_local(message.timestamp),
+                bannerMarkup: true,
+            });
         }
 
         let group = message.direction == NotificationDirection.RECEIVED
             ? 'received' : 'sent';
 
-        this._append({ body: messageBody,
-                       group,
-                       styles,
-                       timestamp: message.timestamp,
-                       noTimestamp });
+        this._append({
+            body: messageBody,
+            group,
+            styles,
+            timestamp: message.timestamp,
+            noTimestamp,
+        });
     }
 
     _filterMessages() {
@@ -761,11 +772,13 @@ var ChatNotification = HAVE_TP ? GObject.registerClass({
      */
     _append(props) {
         let currentTime = Date.now() / 1000;
-        props = Params.parse(props, { body: null,
-                                      group: null,
-                                      styles: [],
-                                      timestamp: currentTime,
-                                      noTimestamp: false });
+        props = Params.parse(props, {
+            body: null,
+            group: null,
+            styles: [],
+            timestamp: currentTime,
+            noTimestamp: false,
+        });
         const { noTimestamp } = props;
         delete props.noTimestamp;
 
@@ -821,9 +834,11 @@ var ChatNotification = HAVE_TP ? GObject.registerClass({
         const message = `<i>${
             _('%s is now known as %s').format(oldAlias, newAlias)}</i>`;
 
-        this._append({ body: message,
-                       group: 'meta',
-                       styles: ['chat-meta-message'] });
+        this._append({
+            body: message,
+            group: 'meta',
+            styles: ['chat-meta-message'],
+        });
 
         this._filterMessages();
     }
@@ -842,9 +857,11 @@ class ChatNotificationBanner extends MessageTray.NotificationBanner {
     _init(notification) {
         super._init(notification);
 
-        this._responseEntry = new St.Entry({ style_class: 'chat-response',
-                                             x_expand: true,
-                                             can_focus: true });
+        this._responseEntry = new St.Entry({
+            style_class: 'chat-response',
+            x_expand: true,
+            can_focus: true,
+        });
         this._responseEntry.clutter_text.connect('activate', this._onEntryActivated.bind(this));
         this._responseEntry.clutter_text.connect('text-changed', this._onEntryChanged.bind(this));
         this.setActionArea(this._responseEntry);
@@ -857,12 +874,16 @@ class ChatNotificationBanner extends MessageTray.NotificationBanner {
             this.emit('unfocused');
         });
 
-        this._scrollArea = new St.ScrollView({ style_class: 'chat-scrollview vfade',
-                                               vscrollbar_policy: St.PolicyType.AUTOMATIC,
-                                               hscrollbar_policy: St.PolicyType.NEVER,
-                                               visible: this.expanded });
-        this._contentArea = new St.BoxLayout({ style_class: 'chat-body',
-                                               vertical: true });
+        this._scrollArea = new St.ScrollView({
+            style_class: 'chat-scrollview vfade',
+            vscrollbar_policy: St.PolicyType.AUTOMATIC,
+            hscrollbar_policy: St.PolicyType.NEVER,
+            visible: this.expanded,
+        });
+        this._contentArea = new St.BoxLayout({
+            style_class: 'chat-body',
+            vertical: true,
+        });
         this._scrollArea.add_actor(this._contentArea);
 
         this.setExpandedBody(this._scrollArea);
index fbc7a0f5fc2ac9507b6e128090edbe9bb327e0d0..421fecf37f8020d720ffcdc78cd48794c6bbac9d 100644 (file)
@@ -18,15 +18,20 @@ var SortGroup = {
 var CtrlAltTabManager = class CtrlAltTabManager {
     constructor() {
         this._items = [];
-        this.addGroup(global.window_group, _("Windows"),
-                      'focus-windows-symbolic', { sortGroup: SortGroup.TOP,
-                                                  focusCallback: this._focusWindows.bind(this) });
+        this.addGroup(global.window_group,
+            _('Windows'),
+            'focus-windows-symbolic', {
+                sortGroup: SortGroup.TOP,
+                focusCallback: this._focusWindows.bind(this),
+            });
     }
 
     addGroup(root, name, icon, params) {
-        let item = Params.parse(params, { sortGroup: SortGroup.MIDDLE,
-                                          proxy: root,
-                                          focusCallback: null });
+        const item = Params.parse(params, {
+            sortGroup: SortGroup.MIDDLE,
+            proxy: root,
+            focusCallback: null,
+        });
 
         item.root = root;
         item.name = name;
@@ -100,14 +105,16 @@ var CtrlAltTabManager = class CtrlAltTabManager {
                     }
                 }
 
-                items.push({ name: windows[i].title,
-                             proxy: windows[i].get_compositor_private(),
-                             focusCallback: timestamp => {
-                                 Main.activateWindow(windows[i], timestamp);
-                             },
-                             iconActor: icon,
-                             iconName,
-                             sortGroup: SortGroup.MIDDLE });
+                items.push({
+                    name: windows[i].title,
+                    proxy: windows[i].get_compositor_private(),
+                    focusCallback: timestamp => {
+                        Main.activateWindow(windows[i], timestamp);
+                    },
+                    iconActor: icon,
+                    iconName,
+                    sortGroup: SortGroup.MIDDLE,
+                });
             }
         }
 
@@ -171,13 +178,17 @@ class CtrlAltTabSwitcher extends SwitcherPopup.SwitcherList {
     }
 
     _addIcon(item) {
-        let box = new St.BoxLayout({ style_class: 'alt-tab-app',
-                                     vertical: true });
+        const box = new St.BoxLayout({
+            style_class: 'alt-tab-app',
+            vertical: true,
+        });
 
         let icon = item.iconActor;
         if (!icon) {
-            icon = new St.Icon({ icon_name: item.iconName,
-                                 icon_size: POPUP_APPICON_SIZE });
+            icon = new St.Icon({
+                icon_name: item.iconName,
+                icon_size: POPUP_APPICON_SIZE,
+            });
         }
         box.add_child(icon);
 
index 7c449f8515657227ebd72d4fd12c42a6c0046af1..e5f81fca74009fcfd3c3b4e74311133273e139e1 100644 (file)
@@ -1,8 +1,7 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 /* exported Dash */
 
-const { Clutter, GLib, GObject,
-        Graphene, Meta, Shell, St } = imports.gi;
+const { Clutter, GLib, GObject, Graphene, Meta, Shell, St } = imports.gi;
 
 const AppDisplay = imports.ui.appDisplay;
 const AppFavorites = imports.ui.appFavorites;
@@ -196,15 +195,18 @@ class ShowAppsIcon extends DashItemContainer {
     _init() {
         super._init();
 
-        this.toggleButton = new St.Button({ style_class: 'show-apps',
-                                            track_hover: true,
-                                            can_focus: true,
-                                            toggle_mode: true });
+        this.toggleButton = new St.Button({
+            style_class: 'show-apps',
+            track_hover: true,
+            can_focus: true,
+            toggle_mode: true,
+        });
         this._iconActor = null;
-        this.icon = new IconGrid.BaseIcon(_("Show Applications"),
-                                          { setSizeManually: true,
-                                            showLabel: false,
-                                            createIcon: this._createIcon.bind(this) });
+        this.icon = new IconGrid.BaseIcon(_('Show Applications'), {
+            setSizeManually: true,
+            showLabel: false,
+            createIcon: this._createIcon.bind(this),
+        });
         this.icon.y_align = Clutter.ActorAlign.CENTER;
 
         this.toggleButton.add_actor(this.icon);
@@ -215,10 +217,12 @@ class ShowAppsIcon extends DashItemContainer {
     }
 
     _createIcon(size) {
-        this._iconActor = new St.Icon({ icon_name: 'view-app-grid-symbolic',
-                                        icon_size: size,
-                                        style_class: 'show-apps-icon',
-                                        track_hover: true });
+        this._iconActor = new St.Icon({
+            icon_name: 'view-app-grid-symbolic',
+            icon_size: size,
+            style_class: 'show-apps-icon',
+            track_hover: true,
+        });
         return this._iconActor;
     }
 
@@ -738,9 +742,11 @@ var Dash = GObject.registerClass({
 
             // App added at newIndex
             if (newApp && !oldApps.includes(newApp)) {
-                addedItems.push({ app: newApp,
-                                  item: this._createAppItem(newApp),
-                                  pos: newIndex });
+                addedItems.push({
+                    app: newApp,
+                    item: this._createAppItem(newApp),
+                    pos: newIndex,
+                });
                 newIndex++;
                 continue;
             }
@@ -756,9 +762,11 @@ var Dash = GObject.registerClass({
 
             if (insertHere || alreadyRemoved) {
                 let newItem = this._createAppItem(newApp);
-                addedItems.push({ app: newApp,
-                                  item: newItem,
-                                  pos: newIndex + removedActors.length });
+                addedItems.push({
+                    app: newApp,
+                    item: newItem,
+                    pos: newIndex + removedActors.length,
+                });
                 newIndex++;
             } else {
                 removedActors.push(children[oldIndex]);
index 55c12ebe13f90617bd81fc72234de62039455689..36fcc10ef05bfdc6d5576c7f84a3effd121be5b0 100644 (file)
@@ -1,8 +1,10 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 /* exported DateMenuButton */
 
-const { Clutter, Gio, GLib, GnomeDesktop,
-        GObject, GWeather, Pango, Shell, St } = imports.gi;
+const {
+    Clutter, Gio, GLib, GnomeDesktop,
+    GObject, GWeather, Pango, Shell, St,
+} = imports.gi;
 
 const Util = imports.misc.util;
 const Main = imports.ui.main;
@@ -49,8 +51,10 @@ class TodayButton extends St.Button {
         let hbox = new St.BoxLayout({ vertical: true });
         this.add_actor(hbox);
 
-        this._dayLabel = new St.Label({ style_class: 'day-label',
-                                        x_align: Clutter.ActorAlign.START });
+        this._dayLabel = new St.Label({
+            style_class: 'day-label',
+            x_align: Clutter.ActorAlign.START,
+        });
         hbox.add_actor(this._dayLabel);
 
         this._dateLabel = new St.Label({ style_class: 'date-label' });
@@ -323,9 +327,11 @@ class WorldClocksSection extends St.Button {
         this._locations = [];
 
         let layout = new Clutter.GridLayout({ orientation: Clutter.Orientation.VERTICAL });
-        this._grid = new St.Widget({ style_class: 'world-clocks-grid',
-                                     x_expand: true,
-                                     layout_manager: layout });
+        this._grid = new St.Widget({
+            style_class: 'world-clocks-grid',
+            x_expand: true,
+            layout_manager: layout,
+        });
         layout.hookup_style(this._grid);
 
         this.child = this._grid;
@@ -389,9 +395,11 @@ class WorldClocksSection extends St.Button {
         let title = this._locations.length == 0
             ? _("Add world clocks…")
             : _("World Clocks");
-        let header = new St.Label({ style_class: 'world-clocks-header',
-                                    x_align: Clutter.ActorAlign.START,
-                                    text: title });
+        const header = new St.Label({
+            style_class: 'world-clocks-header',
+            x_align: Clutter.ActorAlign.START,
+            text: title,
+        });
         layout.attach(header, 0, 0, 2, 1);
         this.label_actor = header;
 
@@ -399,11 +407,13 @@ class WorldClocksSection extends St.Button {
             let l = this._locations[i].location;
 
             let name = l.get_city_name() || l.get_name();
-            let label = new St.Label({ style_class: 'world-clocks-city',
-                                       text: name,
-                                       x_align: Clutter.ActorAlign.START,
-                                       y_align: Clutter.ActorAlign.CENTER,
-                                       x_expand: true });
+            const label = new St.Label({
+                style_class: 'world-clocks-city',
+                text: name,
+                x_align: Clutter.ActorAlign.START,
+                y_align: Clutter.ActorAlign.CENTER,
+                x_expand: true,
+            });
 
             let time = new St.Label({ style_class: 'world-clocks-time' });
 
@@ -821,7 +831,6 @@ var DateMenuButton = GObject.registerClass(
 class DateMenuButton extends PanelMenu.Button {
     _init() {
         let hbox;
-        let vbox;
 
         super._init(0.5);
 
@@ -882,23 +891,29 @@ class DateMenuButton extends PanelMenu.Button {
 
         // Fill up the second column
         const boxLayout = new CalendarColumnLayout([this._calendar, this._date]);
-        vbox = new St.Widget({ style_class: 'datemenu-calendar-column',
-                               layout_manager: boxLayout });
+        const vbox = new St.Widget({
+            style_class: 'datemenu-calendar-column',
+            layout_manager: boxLayout,
+        });
         boxLayout.hookup_style(vbox);
         hbox.add(vbox);
 
         vbox.add_actor(this._date);
         vbox.add_actor(this._calendar);
 
-        this._displaysSection = new St.ScrollView({ style_class: 'datemenu-displays-section vfade',
-                                                    x_expand: true,
-                                                    overlay_scrollbars: true });
+        this._displaysSection = new St.ScrollView({
+            style_class: 'datemenu-displays-section vfade',
+            x_expand: true,
+            overlay_scrollbars: true,
+        });
         this._displaysSection.set_policy(St.PolicyType.NEVER, St.PolicyType.EXTERNAL);
         vbox.add_actor(this._displaysSection);
 
-        let displaysBox = new St.BoxLayout({ vertical: true,
-                                             x_expand: true,
-                                             style_class: 'datemenu-displays-box' });
+        const displaysBox = new St.BoxLayout({
+            vertical: true,
+            x_expand: true,
+            style_class: 'datemenu-displays-box',
+        });
         this._displaysSection.add_actor(displaysBox);
 
         this._eventsItem = new EventsSection();
index f4227c2e092d65c665a18e587deb72d28cfe8f1f..94e0bef2485ed845ab598ee3072d217a1b92a072 100644 (file)
  * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
-const { AccountsService, Clutter, Gio,
-        GLib, GObject, Pango, Polkit, Shell, St, UPowerGlib: UPower }  = imports.gi;
+const {
+    AccountsService, Clutter, Gio, GLib, GObject,
+    Pango, Polkit, Shell, St, UPowerGlib: UPower,
+} = imports.gi;
 
 const CheckBox = imports.ui.checkBox;
 const Dialog = imports.ui.dialog;
@@ -226,8 +228,10 @@ function init() {
 var EndSessionDialog = GObject.registerClass(
 class EndSessionDialog extends ModalDialog.ModalDialog {
     _init() {
-        super._init({ styleClass: 'end-session-dialog',
-                      destroyOnClose: false });
+        super._init({
+            styleClass: 'end-session-dialog',
+            destroyOnClose: false,
+        });
 
         this._loginManager = LoginManager.getLoginManager();
         this._loginManager.canRebootToBootLoaderMenu(
@@ -434,9 +438,11 @@ class EndSessionDialog extends ModalDialog.ModalDialog {
     _updateButtons() {
         this.clearButtons();
 
-        this.addButton({ action: this.cancel.bind(this),
-                         label: _("Cancel"),
-                         key: Clutter.KEY_Escape });
+        this.addButton({
+            action: this.cancel.bind(this),
+            label: _('Cancel'),
+            key: Clutter.KEY_Escape,
+        });
 
         let dialogContent = DialogContent[this._type];
         for (let i = 0; i < dialogContent.confirmButtons.length; i++) {
@@ -669,10 +675,12 @@ class EndSessionDialog extends ModalDialog.ModalDialog {
                 if (proxy.Id == sessionId)
                     continue;
 
-                let session = { user: this._userManager.get_user(userName),
-                                username: userName,
-                                type: proxy.Type,
-                                remote: proxy.Remote };
+                const session = {
+                    user: this._userManager.get_user(userName),
+                    username: userName,
+                    type: proxy.Type,
+                    remote: proxy.Remote,
+                };
                 this._sessions.push(session);
 
                 let userAvatar = new UserWidget.Avatar(session.user, { iconSize: _ITEM_ICON_SIZE });
index e1225257bd748c4dc03b68e150b0caf003786745..099cf10f6b3ec028feac877e8c3393bdf86722b4 100644 (file)
@@ -327,8 +327,10 @@ function init() {
     // Miscellaneous monkeypatching
     _patchContainerClass(St.BoxLayout);
 
-    _patchLayoutClass(Clutter.GridLayout, { row_spacing: 'spacing-rows',
-                                            column_spacing: 'spacing-columns' });
+    _patchLayoutClass(Clutter.GridLayout, {
+        row_spacing: 'spacing-rows',
+        column_spacing: 'spacing-columns',
+    });
     _patchLayoutClass(Clutter.BoxLayout, { spacing: 'spacing' });
 
     let origSetEasingDuration = Clutter.Actor.prototype.set_easing_duration;
index 05fe82a31ae7d4a537b93e1ee6ce83c63b4a3b5b..a46bab0fa9be2d2ae3617924283cac04177d39ca 100644 (file)
@@ -111,9 +111,11 @@ var GrabHelper = class GrabHelper {
     // use cases like menus, where we want to grab the menu actor, but keep
     // focus on the clicked on menu item.
     grab(params) {
-        params = Params.parse(params, { actor: null,
-                                        focus: null,
-                                        onUngrab: null });
+        params = Params.parse(params, {
+            actor: null,
+            focus: null,
+            onUngrab: null,
+        });
 
         let focus = global.stage.key_focus;
         let hadFocus = focus && this._isWithinGrabbedActor(focus);
@@ -202,8 +204,10 @@ var GrabHelper = class GrabHelper {
     // The onUngrab callback for every grab is called for every popped
     // grab with the parameter %false.
     ungrab(params) {
-        params = Params.parse(params, { actor: this.currentGrab.actor,
-                                        isUser: false });
+        params = Params.parse(params, {
+            actor: this.currentGrab.actor,
+            isUser: false,
+        });
 
         let grabStackIndex = this._findStackIndex(params.actor);
         if (grabStackIndex < 0)
index 68c14b8bbec0102687455c1b7b31159ef897af50..22bff9f9e0b2764695b29b0c6d1c2061defb5aeb 100644 (file)
@@ -34,9 +34,11 @@ var CandidateArea = GObject.registerClass({
         });
         this._candidateBoxes = [];
         for (let i = 0; i < MAX_CANDIDATES_PER_PAGE; ++i) {
-            let box = new St.BoxLayout({ style_class: 'candidate-box',
-                                         reactive: true,
-                                         track_hover: true });
+            const box = new St.BoxLayout({
+                style_class: 'candidate-box',
+                reactive: true,
+                track_hover: true,
+            });
             box._indexLabel = new St.Label({ style_class: 'candidate-index' });
             box._candidateLabel = new St.Label({ style_class: 'candidate-label' });
             box.add_child(box._indexLabel);
@@ -155,16 +157,22 @@ class IbusCandidatePopup extends BoxPointer.BoxPointer {
 
         Main.layoutManager.addChrome(this);
 
-        let box = new St.BoxLayout({ style_class: 'candidate-popup-content',
-                                     vertical: true });
+        const box = new St.BoxLayout({
+            style_class: 'candidate-popup-content',
+            vertical: true,
+        });
         this.bin.set_child(box);
 
-        this._preeditText = new St.Label({ style_class: 'candidate-popup-text',
-                                           visible: false });
+        this._preeditText = new St.Label({
+            style_class: 'candidate-popup-text',
+            visible: false,
+        });
         box.add(this._preeditText);
 
-        this._auxText = new St.Label({ style_class: 'candidate-popup-text',
-                                       visible: false });
+        this._auxText = new St.Label({
+            style_class: 'candidate-popup-text',
+            visible: false,
+        });
         box.add(this._auxText);
 
         this._candidateArea = new CandidateArea();
index 84081a9c523a164ed78c9cf130a45a1eadfaaff2..dec522c83ad1c5d4c470adb7c28669d49a40a47b 100644 (file)
@@ -97,19 +97,23 @@ var InhibitShortcutsDialog = GObject.registerClass({
 
         this._dialog.contentLayout.add_child(content);
 
-        this._dialog.addButton({ label: _("Deny"),
-                                 action: () => {
-                                     this._saveToPermissionStore(DENIED);
-                                     this._emitResponse(DialogResponse.DENY);
-                                 },
-                                 key: Clutter.KEY_Escape });
-
-        this._dialog.addButton({ label: _("Allow"),
-                                 action: () => {
-                                     this._saveToPermissionStore(GRANTED);
-                                     this._emitResponse(DialogResponse.ALLOW);
-                                 },
-                                 default: true });
+        this._dialog.addButton({
+            label: _('Deny'),
+            action: () => {
+                this._saveToPermissionStore(DENIED);
+                this._emitResponse(DialogResponse.DENY);
+            },
+            key: Clutter.KEY_Escape,
+        });
+
+        this._dialog.addButton({
+            label: _('Allow'),
+            action: () => {
+                this._saveToPermissionStore(GRANTED);
+                this._emitResponse(DialogResponse.ALLOW);
+            },
+            default: true,
+        });
     }
 
     _emitResponse(response) {
index a45e02443d80688edc0ee9c85107b250e9bf2b76..920be00161b270acf6f94faf49f44808ceddbb15 100644 (file)
@@ -51,21 +51,25 @@ class KbdA11yDialog extends GObject.Object {
         let content = new Dialog.MessageDialogContent({ title, description });
         dialog.contentLayout.add_child(content);
 
-        dialog.addButton({ label: enabled ? _("Leave On") : _("Turn On"),
-                           action: () => {
-                               this._a11ySettings.set_boolean(key, true);
-                               dialog.close();
-                           },
-                           default: enabled,
-                           key: !enabled ? Clutter.KEY_Escape : null });
+        dialog.addButton({
+            label: enabled ? _('Leave On') : _('Turn On'),
+            action: () => {
+                this._a11ySettings.set_boolean(key, true);
+                dialog.close();
+            },
+            default: enabled,
+            key: !enabled ? Clutter.KEY_Escape : null,
+        });
 
-        dialog.addButton({ label: enabled ? _("Turn Off") : _("Leave Off"),
-                           action: () => {
-                               this._a11ySettings.set_boolean(key, false);
-                               dialog.close();
-                           },
-                           default: !enabled,
-                           key: enabled ? Clutter.KEY_Escape : null });
+        dialog.addButton({
+            label: enabled ? _('Turn Off') : _('Leave Off'),
+            action: () => {
+                this._a11ySettings.set_boolean(key, false);
+                dialog.close();
+            },
+            default: !enabled,
+            key: enabled ? Clutter.KEY_Escape : null,
+        });
 
         dialog.open();
     }
index 75df02de66658b28336d6d64cd85aa114052c523..6ee82a30285ee6336a3d33d0232b52529c9ba3c5 100644 (file)
@@ -127,9 +127,11 @@ class AspectContainer extends St.Widget {
 var KeyContainer = GObject.registerClass(
 class KeyContainer extends St.Widget {
     _init() {
-        let gridLayout = new Clutter.GridLayout({ orientation: Clutter.Orientation.HORIZONTAL,
-                                                  column_homogeneous: true,
-                                                  row_homogeneous: true });
+        const gridLayout = new Clutter.GridLayout({
+            orientation: Clutter.Orientation.HORIZONTAL,
+            column_homogeneous: true,
+            row_homogeneous: true,
+        });
         super._init({
             layout_manager: gridLayout,
             x_expand: true,
@@ -880,13 +882,17 @@ var EmojiPager = GObject.registerClass({
     }
 
     _generatePanel(nPage) {
-        let gridLayout = new Clutter.GridLayout({ orientation: Clutter.Orientation.HORIZONTAL,
-                                                  column_homogeneous: true,
-                                                  row_homogeneous: true });
-        let panel = new St.Widget({ layout_manager: gridLayout,
-                                    style_class: 'emoji-page',
-                                    x_expand: true,
-                                    y_expand: true });
+        const gridLayout = new Clutter.GridLayout({
+            orientation: Clutter.Orientation.HORIZONTAL,
+            column_homogeneous: true,
+            row_homogeneous: true,
+        });
+        const panel = new St.Widget({
+            layout_manager: gridLayout,
+            style_class: 'emoji-page',
+            x_expand: true,
+            y_expand: true,
+        });
 
         /* Set an expander actor so all proportions are right despite the panel
          * not having all rows/cols filled in.
@@ -1119,8 +1125,11 @@ var EmojiSelection = GObject.registerClass({
         row.appendKey(key);
         row.layoutButtons();
 
-        let actor = new AspectContainer({ layout_manager: new Clutter.BinLayout(),
-                                          x_expand: true, y_expand: true });
+        const actor = new AspectContainer({
+            layout_manager: new Clutter.BinLayout(),
+            x_expand: true,
+            y_expand: true,
+        });
         actor.add_child(row);
         /* Regular keyboard layouts are 11.5×4 grids, optimize for that
          * at the moment. Ideally this should be as wide as the current
@@ -1159,9 +1168,11 @@ var Keypad = GObject.registerClass({
             y_expand: true,
         });
 
-        let gridLayout = new Clutter.GridLayout({ orientation: Clutter.Orientation.HORIZONTAL,
-                                                  column_homogeneous: true,
-                                                  row_homogeneous: true });
+        const gridLayout = new Clutter.GridLayout({
+            orientation: Clutter.Orientation.HORIZONTAL,
+            column_homogeneous: true,
+            row_homogeneous: true,
+        });
         this._box = new St.Widget({ layout_manager: gridLayout, x_expand: true, y_expand: true });
         this.add_child(this._box);
 
index 68941049d231e8354f41a10d3679c2578c8c436f..d03a72dbda07fd046ff16873bdf0c8661b87068e 100644 (file)
@@ -229,9 +229,11 @@ var LayoutManager = GObject.registerClass({
         global.stage.remove_actor(global.top_window_group);
         this.uiGroup.add_actor(global.top_window_group);
 
-        this.overviewGroup = new St.Widget({ name: 'overviewGroup',
-                                             visible: false,
-                                             reactive: true });
+        this.overviewGroup = new St.Widget({
+            name: 'overviewGroup',
+            visible: false,
+            reactive: true,
+        });
         this.addChrome(this.overviewGroup);
 
         this.screenShieldGroup = new St.Widget({
@@ -242,20 +244,28 @@ var LayoutManager = GObject.registerClass({
         });
         this.addChrome(this.screenShieldGroup);
 
-        this.panelBox = new St.BoxLayout({ name: 'panelBox',
-                                           vertical: true });
-        this.addChrome(this.panelBox, { affectsStruts: true,
-                                        trackFullscreen: true });
+        this.panelBox = new St.BoxLayout({
+            name: 'panelBox',
+            vertical: true,
+        });
+        this.addChrome(this.panelBox, {
+            affectsStruts: true,
+            trackFullscreen: true,
+        });
         this.panelBox.connect('notify::allocation',
                               this._panelBoxChanged.bind(this));
 
-        this.modalDialogGroup = new St.Widget({ name: 'modalDialogGroup',
-                                                layout_manager: new Clutter.BinLayout() });
+        this.modalDialogGroup = new St.Widget({
+            name: 'modalDialogGroup',
+            layout_manager: new Clutter.BinLayout(),
+        });
         this.uiGroup.add_actor(this.modalDialogGroup);
 
-        this.keyboardBox = new St.BoxLayout({ name: 'keyboardBox',
-                                              reactive: true,
-                                              track_hover: true });
+        this.keyboardBox = new St.BoxLayout({
+            name: 'keyboardBox',
+            reactive: true,
+            track_hover: true,
+        });
         this.addTopChrome(this.keyboardBox);
         this._keyboardHeightNotifyId = 0;
 
@@ -448,9 +458,11 @@ var LayoutManager = GObject.registerClass({
     }
 
     _createBackgroundManager(monitorIndex) {
-        let bgManager = new Background.BackgroundManager({ container: this._backgroundGroup,
-                                                           layoutManager: this,
-                                                           monitorIndex });
+        const bgManager = new Background.BackgroundManager({
+            container: this._backgroundGroup,
+            layoutManager: this,
+            monitorIndex,
+        });
 
         bgManager.connect('changed', this._addBackgroundMenu.bind(this));
         this._addBackgroundMenu(bgManager);
@@ -543,10 +555,12 @@ var LayoutManager = GObject.registerClass({
         if (this.panelBox.height) {
             let primary = this.primaryMonitor;
 
-            this._rightPanelBarrier = new Meta.Barrier({ display: global.display,
-                                                         x1: primary.x + primary.width, y1: primary.y,
-                                                         x2: primary.x + primary.width, y2: primary.y + this.panelBox.height,
-                                                         directions: Meta.BarrierDirection.NEGATIVE_X });
+            this._rightPanelBarrier = new Meta.Barrier({
+                display: global.display,
+                x1: primary.x + primary.width, y1: primary.y,
+                x2: primary.x + primary.width, y2: primary.y + this.panelBox.height,
+                directions: Meta.BarrierDirection.NEGATIVE_X,
+            });
         }
     }
 
@@ -620,8 +634,10 @@ var LayoutManager = GObject.registerClass({
 
         global.stage.insert_child_below(this._systemBackground, null);
 
-        let constraint = new Clutter.BindConstraint({ source: global.stage,
-                                                      coordinate: Clutter.BindCoordinate.ALL });
+        const constraint = new Clutter.BindConstraint({
+            source: global.stage,
+            coordinate: Clutter.BindCoordinate.ALL,
+        });
         this._systemBackground.add_constraint(constraint);
 
         let signalId = this._systemBackground.connect('loaded', () => {
@@ -661,10 +677,12 @@ var LayoutManager = GObject.registerClass({
     async _prepareStartupAnimation() {
         // During the initial transition, add a simple actor to block all events,
         // so they don't get delivered to X11 windows that have been transformed.
-        this._coverPane = new Clutter.Actor({ opacity: 0,
-                                              width: global.screen_width,
-                                              height: global.screen_height,
-                                              reactive: true });
+        this._coverPane = new Clutter.Actor({
+            opacity: 0,
+            width: global.screen_width,
+            height: global.screen_height,
+            reactive: true,
+        });
         this.addChrome(this._coverPane);
 
         if (Meta.is_restart()) {
@@ -1133,19 +1151,27 @@ class HotCorner extends Clutter.Actor {
 
         if (size > 0) {
             if (Clutter.get_default_text_direction() == Clutter.TextDirection.RTL) {
-                this._verticalBarrier = new Meta.Barrier({ display: global.display,
-                                                           x1: this._x, x2: this._x, y1: this._y, y2: this._y + size,
-                                                           directions: Meta.BarrierDirection.NEGATIVE_X });
-                this._horizontalBarrier = new Meta.Barrier({ display: global.display,
-                                                             x1: this._x - size, x2: this._x, y1: this._y, y2: this._y,
-                                                             directions: Meta.BarrierDirection.POSITIVE_Y });
+                this._verticalBarrier = new Meta.Barrier({
+                    display: global.display,
+                    x1: this._x, x2: this._x, y1: this._y, y2: this._y + size,
+                    directions: Meta.BarrierDirection.NEGATIVE_X,
+                });
+                this._horizontalBarrier = new Meta.Barrier({
+                    display: global.display,
+                    x1: this._x - size, x2: this._x, y1: this._y, y2: this._y,
+                    directions: Meta.BarrierDirection.POSITIVE_Y,
+                });
             } else {
-                this._verticalBarrier = new Meta.Barrier({ display: global.display,
-                                                           x1: this._x, x2: this._x, y1: this._y, y2: this._y + size,
-                                                           directions: Meta.BarrierDirection.POSITIVE_X });
-                this._horizontalBarrier = new Meta.Barrier({ display: global.display,
-                                                             x1: this._x, x2: this._x + size, y1: this._y, y2: this._y,
-                                                             directions: Meta.BarrierDirection.POSITIVE_Y });
+                this._verticalBarrier = new Meta.Barrier({
+                    display: global.display,
+                    x1: this._x, x2: this._x, y1: this._y, y2: this._y + size,
+                    directions: Meta.BarrierDirection.POSITIVE_X,
+                });
+                this._horizontalBarrier = new Meta.Barrier({
+                    display: global.display,
+                    x1: this._x, x2: this._x + size, y1: this._y, y2: this._y,
+                    directions: Meta.BarrierDirection.POSITIVE_Y,
+                });
             }
 
             this._pressureBarrier.addBarrier(this._verticalBarrier);
@@ -1164,11 +1190,13 @@ class HotCorner extends Clutter.Actor {
                 reactive: true,
             });
 
-            this._corner = new Clutter.Actor({ name: 'hot-corner',
-                                               width: 1,
-                                               height: 1,
-                                               opacity: 0,
-                                               reactive: true });
+            this._corner = new Clutter.Actor({
+                name: 'hot-corner',
+                width: 1,
+                height: 1,
+                opacity: 0,
+                reactive: true,
+            });
             this._corner._delegate = this;
 
             this.add_child(this._corner);
index bff753ec50ffd00e4c6fff48d0f007a7bae6a099..96f4d9cd7715a58826da0d5efb4dac101a4701a3 100644 (file)
@@ -1,8 +1,9 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 /* exported LookingGlass */
 
-const { Clutter, Cogl, Gio, GLib, GObject,
-        Graphene, Meta, Pango, Shell, St } = imports.gi;
+const {
+    Clutter, Cogl, Gio, GLib, GObject, Graphene, Meta, Pango, Shell, St,
+} = imports.gi;
 const Signals = imports.signals;
 const System = imports.system;
 
@@ -94,13 +95,17 @@ var AutoComplete = class AutoComplete {
             let [completions, attrHead] = JsParse.getCompletions(text, commandHeader, AUTO_COMPLETE_GLOBAL_KEYWORDS);
             let currTime = global.get_current_time();
             if ((currTime - this._lastTabTime) < AUTO_COMPLETE_DOUBLE_TAB_DELAY) {
-                this._processCompletionRequest({ tabType: 'double',
-                                                 completions,
-                                                 attrHead });
+                this._processCompletionRequest({
+                    tabType: 'double',
+                    completions,
+                    attrHead,
+                });
             } else {
-                this._processCompletionRequest({ tabType: 'single',
-                                                 completions,
-                                                 attrHead });
+                this._processCompletionRequest({
+                    tabType: 'single',
+                    completions,
+                    attrHead,
+                });
             }
             this._lastTabTime = currTime;
         }
@@ -135,9 +140,11 @@ var Notebook = GObject.registerClass({
     }
 
     appendPage(name, child) {
-        let labelBox = new St.BoxLayout({ style_class: 'notebook-tab',
-                                          reactive: true,
-                                          track_hover: true });
+        const labelBox = new St.BoxLayout({
+            style_class: 'notebook-tab',
+            reactive: true,
+            track_hover: true,
+        });
         let label = new St.Button({ label: name });
         label.connect('clicked', () => {
             this.selectChild(child);
@@ -150,11 +157,13 @@ var Notebook = GObject.registerClass({
         scrollview.get_hscroll_bar().hide();
         scrollview.add_actor(child);
 
-        let tabData = { child,
-                        labelBox,
-                        label,
-                        scrollView: scrollview,
-                        _scrollToBottom: false };
+        const tabData = {
+            child,
+            labelBox,
+            label,
+            scrollView: scrollview,
+            _scrollToBottom: false,
+        };
         this._tabs.push(tabData);
         scrollview.hide();
         this.add_child(scrollview);
@@ -531,17 +540,21 @@ class RedBorderEffect extends Clutter.Effect {
 });
 
 var Inspector = GObject.registerClass({
-    Signals: { 'closed': {},
-               'target': { param_types: [Clutter.Actor.$gtype, GObject.TYPE_DOUBLE, GObject.TYPE_DOUBLE] } },
+    Signals: {
+        'closed': {},
+        'target': { param_types: [Clutter.Actor.$gtype, GObject.TYPE_DOUBLE, GObject.TYPE_DOUBLE] },
+    },
 }, class Inspector extends Clutter.Actor {
     _init(lookingGlass) {
         super._init({ width: 0, height: 0 });
 
         Main.uiGroup.add_actor(this);
 
-        let eventHandler = new St.BoxLayout({ name: 'LookingGlassDialog',
-                                              vertical: false,
-                                              reactive: true });
+        const eventHandler = new St.BoxLayout({
+            name: 'LookingGlassDialog',
+            vertical: false,
+            reactive: true,
+        });
         this._eventHandler = eventHandler;
         this.add_actor(eventHandler);
         this._displayText = new St.Label({ x_expand: true });
@@ -673,11 +686,15 @@ var Extensions = GObject.registerClass({
         super._init({ vertical: true, name: 'lookingGlassExtensions' });
 
         this._lookingGlass = lookingGlass;
-        this._noExtensions = new St.Label({ style_class: 'lg-extensions-none',
-                                            text: _("No extensions installed") });
+        this._noExtensions = new St.Label({
+            style_class: 'lg-extensions-none',
+            text: _('No extensions installed'),
+        });
         this._numExtensions = 0;
-        this._extensionsList = new St.BoxLayout({ vertical: true,
-                                                  style_class: 'lg-extensions-list' });
+        this._extensionsList = new St.BoxLayout({
+            vertical: true,
+            style_class: 'lg-extensions-list',
+        });
         this._extensionsList.add(this._noExtensions);
         this.add(this._extensionsList);
 
@@ -783,32 +800,40 @@ var Extensions = GObject.registerClass({
 
         let metaBox = new St.BoxLayout({ style_class: 'lg-extension-meta' });
         box.add(metaBox);
-        let state = new St.Label({ style_class: 'lg-extension-state',
-                                   text: this._stateToString(extension.state) });
+        const state = new St.Label({
+            style_class: 'lg-extension-state',
+            text: this._stateToString(extension.state),
+        });
         metaBox.add(state);
 
-        let viewsource = new St.Button({ reactive: true,
-                                         track_hover: true,
-                                         style_class: 'shell-link',
-                                         label: _("View Source") });
+        const viewsource = new St.Button({
+            reactive: true,
+            track_hover: true,
+            style_class: 'shell-link',
+            label: _('View Source'),
+        });
         viewsource._extension = extension;
         viewsource.connect('clicked', this._onViewSource.bind(this));
         metaBox.add(viewsource);
 
         if (extension.metadata.url) {
-            let webpage = new St.Button({ reactive: true,
-                                          track_hover: true,
-                                          style_class: 'shell-link',
-                                          label: _("Web Page") });
+            const webpage = new St.Button({
+                reactive: true,
+                track_hover: true,
+                style_class: 'shell-link',
+                label: _('Web Page'),
+            });
             webpage._extension = extension;
             webpage.connect('clicked', this._onWebPage.bind(this));
             metaBox.add(webpage);
         }
 
-        let viewerrors = new St.Button({ reactive: true,
-                                         track_hover: true,
-                                         style_class: 'shell-link',
-                                         label: _("Show Errors") });
+        const viewerrors = new St.Button({
+            reactive: true,
+            track_hover: true,
+            style_class: 'shell-link',
+            label: _('Show Errors'),
+        });
         viewerrors._extension = extension;
         viewerrors._parentBox = box;
         viewerrors._isShowing = false;
@@ -1358,8 +1383,10 @@ class LookingGlass extends St.BoxLayout {
             return true;
         });
 
-        this._history = new History.HistoryManager({ gsettingsKey: HISTORY_KEY,
-                                                     entry: this._entry.clutter_text });
+        this._history = new History.HistoryManager({
+            gsettingsKey: HISTORY_KEY,
+            entry: this._entry.clutter_text,
+        });
 
         this._autoComplete = new AutoComplete(this._entry);
         this._autoComplete.connect('suggest', (a, e) => {
index da4c53f8e60ca69fdb57a02cbad95759e8e68025..bd66bc4794ba5a0d42b94cd1fc977abfc335408e 100644 (file)
@@ -1,7 +1,8 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 
-const { Atspi, Clutter, GDesktopEnums,
-        Gio, GLib, GObject, Meta, Shell, St } = imports.gi;
+const {
+    Atspi, Clutter, GDesktopEnums, Gio, GLib, GObject, Meta, Shell, St,
+} = imports.gi;
 const Signals = imports.signals;
 
 const Background = imports.ui.background;
@@ -884,10 +885,12 @@ var ZoomRegion = class ZoomRegion {
      *     magnification factor to of the magnified view.
      */
     setMagFactor(xMagFactor, yMagFactor) {
-        this._changeROI({ xMagFactor,
-                          yMagFactor,
-                          redoCursorTracking: this._followingCursor,
-                          animate: true });
+        this._changeROI({
+            xMagFactor,
+            yMagFactor,
+            redoCursorTracking: this._followingCursor,
+            animate: true,
+        });
     }
 
     /**
@@ -981,10 +984,12 @@ var ZoomRegion = class ZoomRegion {
             return;
 
         this._followingCursor = false;
-        this._changeROI({ xMagFactor: this._viewPortWidth / roi.width,
-                          yMagFactor: this._viewPortHeight / roi.height,
-                          xCenter: roi.x + roi.width  / 2,
-                          yCenter: roi.y + roi.height / 2 });
+        this._changeROI({
+            xMagFactor: this._viewPortWidth / roi.width,
+            yMagFactor: this._viewPortHeight / roi.height,
+            xCenter: roi.x + roi.width  / 2,
+            yCenter: roi.y + roi.height / 2,
+        });
     }
 
     /**
@@ -1209,9 +1214,11 @@ var ZoomRegion = class ZoomRegion {
         this._clearScrollContentsTimer();
 
         this._followingCursor = false;
-        this._changeROI({ xCenter: x,
-                          yCenter: y,
-                          animate: true });
+        this._changeROI({
+            xCenter: x,
+            yCenter: y,
+            animate: true,
+        });
     }
 
     /**
@@ -1345,8 +1352,10 @@ var ZoomRegion = class ZoomRegion {
 
         // Clone the group that contains all of UI on the screen.  This is the
         // chrome, the windows, etc.
-        this._uiGroupClone = new Clutter.Clone({ source: Main.uiGroup,
-                                                 clip_to_allocation: true });
+        this._uiGroupClone = new Clutter.Clone({
+            source: Main.uiGroup,
+            clip_to_allocation: true,
+        });
         mainGroup.add_actor(this._uiGroupClone);
 
         // Add either the given mouseSourceActor to the ZoomRegion, or a clone of
@@ -1419,12 +1428,14 @@ var ZoomRegion = class ZoomRegion {
         // and center can be set explicitly, or we can recompute
         // the position based on the mouse cursor position
 
-        params = Params.parse(params, { xMagFactor: this._xMagFactor,
-                                        yMagFactor: this._yMagFactor,
-                                        xCenter: this._xCenter,
-                                        yCenter: this._yCenter,
-                                        redoCursorTracking: false,
-                                        animate: false });
+        params = Params.parse(params, {
+            xMagFactor: this._xMagFactor,
+            yMagFactor: this._yMagFactor,
+            xCenter: this._xCenter,
+            yCenter: this._yCenter,
+            redoCursorTracking: false,
+            animate: false,
+        });
 
         if (params.xMagFactor <= 0)
             params.xMagFactor = this._xMagFactor;
@@ -1457,10 +1468,12 @@ var ZoomRegion = class ZoomRegion {
         // over the actual mouse. However, in full screen mode, the "lens" is
         // the size of the screen -- pointless to move such a large lens around.
         if (this._lensMode && !this._isFullScreen()) {
-            this._setViewPort({ x: this._xCenter - this._viewPortWidth / 2,
-                                y: this._yCenter - this._viewPortHeight / 2,
-                                width: this._viewPortWidth,
-                                height: this._viewPortHeight }, true);
+            this._setViewPort({
+                x: this._xCenter - this._viewPortWidth / 2,
+                y: this._yCenter - this._viewPortHeight / 2,
+                width: this._viewPortWidth,
+                height: this._viewPortHeight,
+            }, true);
         }
 
         this._updateCloneGeometry(params.animate);
index 3d7a044c42f2a56e0e635fe73be768cbe8d37d1a..76223b9c2a10829dcf61629f549a5cb5aa5872d8 100644 (file)
@@ -555,9 +555,11 @@ function _findModal(grab) {
  * @returns {Clutter.Grab}: the grab handle created
  */
 function pushModal(actor, params) {
-    params = Params.parse(params, { timestamp: global.get_current_time(),
-                                    options: 0,
-                                    actionMode: Shell.ActionMode.NONE });
+    params = Params.parse(params, {
+        timestamp: global.get_current_time(),
+        options: 0,
+        actionMode: Shell.ActionMode.NONE,
+    });
 
     let grab = global.stage.grab(actor);
 
@@ -582,7 +584,8 @@ function pushModal(actor, params) {
                 modalActorFocusStack[index].prevFocus = null;
         });
     }
-    modalActorFocusStack.push({ actor,
+    modalActorFocusStack.push({
+        actor,
         grab,
         destroyId: actorDestroyId,
         prevFocus,
@@ -788,8 +791,10 @@ function _queueBeforeRedraw(workId) {
 function initializeDeferredWork(actor, callback) {
     // Turn into a string so we can use as an object property
     let workId = `${++_deferredWorkSequence}`;
-    _deferredWorkData[workId] = { actor,
-                                  callback };
+    _deferredWorkData[workId] = {
+        actor,
+        callback,
+    };
     actor.connect('notify::mapped', () => {
         if (!(actor.mapped && _deferredWorkQueue.includes(workId)))
             return;
@@ -838,10 +843,12 @@ function queueDeferredWork(workId) {
 var RestartMessage = GObject.registerClass(
 class RestartMessage extends ModalDialog.ModalDialog {
     _init(message) {
-        super._init({ shellReactive: true,
-                      styleClass: 'restart-message headline',
-                      shouldFadeIn: false,
-                      destroyOnClose: true });
+        super._init({
+            shellReactive: true,
+            styleClass: 'restart-message headline',
+            shouldFadeIn: false,
+            destroyOnClose: true,
+        });
 
         let label = new St.Label({
             text: message,
index a8431ac54e5dc6ffe330f81fc29ce4a499193fb9..fb87fbdc724183e59cb31a43e2f0f054a2332563 100644 (file)
@@ -1,6 +1,7 @@
 /* exported MessageListSection */
-const { Atk, Clutter, Gio, GLib,
-        GObject, Graphene, Meta, Pango, St } = imports.gi;
+const {
+    Atk, Clutter, Gio, GLib, GObject, Graphene, Meta, Pango, St,
+} = imports.gi;
 const Main = imports.ui.main;
 const MessageTray = imports.ui.messageTray;
 
@@ -331,18 +332,25 @@ var Message = GObject.registerClass({
         let hbox = new St.BoxLayout();
         vbox.add_actor(hbox);
 
-        this._actionBin = new St.Widget({ layout_manager: new ScaleLayout(),
-                                          visible: false });
+        this._actionBin = new St.Widget({
+            layout_manager: new ScaleLayout(),
+            visible: false,
+        });
         vbox.add_actor(this._actionBin);
 
-        this._iconBin = new St.Bin({ style_class: 'message-icon-bin',
-                                     y_expand: true,
-                                     y_align: Clutter.ActorAlign.START,
-                                     visible: false });
+        this._iconBin = new St.Bin({
+            style_class: 'message-icon-bin',
+            y_expand: true,
+            y_align: Clutter.ActorAlign.START,
+            visible: false,
+        });
         hbox.add_actor(this._iconBin);
 
-        let contentBox = new St.BoxLayout({ style_class: 'message-content',
-                                            vertical: true, x_expand: true });
+        const contentBox = new St.BoxLayout({
+            style_class: 'message-content',
+            vertical: true,
+            x_expand: true,
+        });
         hbox.add_actor(contentBox);
 
         this._mediaControls = new St.BoxLayout();
@@ -361,8 +369,10 @@ var Message = GObject.registerClass({
         });
         titleBox.add_actor(this._secondaryBin);
 
-        let closeIcon = new St.Icon({ icon_name: 'window-close-symbolic',
-                                      icon_size: 16 });
+        const closeIcon = new St.Icon({
+            icon_name: 'window-close-symbolic',
+            icon_size: 16,
+        });
         this._closeButton = new St.Button({
             style_class: 'message-close-button',
             child: closeIcon, opacity: 0,
@@ -435,8 +445,10 @@ var Message = GObject.registerClass({
 
     addMediaControl(iconName, callback) {
         let icon = new St.Icon({ icon_name: iconName, icon_size: 16 });
-        let button = new St.Button({ style_class: 'message-media-control',
-                                     child: icon });
+        const button = new St.Button({
+            style_class: 'message-media-control',
+            child: icon,
+        });
         button.connect('clicked', callback);
         this._mediaControls.add_actor(button);
         return button;
@@ -565,8 +577,10 @@ var MessageListSection = GObject.registerClass({
             x_expand: true,
         });
 
-        this._list = new St.BoxLayout({ style_class: 'message-list-section-list',
-                                        vertical: true });
+        this._list = new St.BoxLayout({
+            style_class: 'message-list-section-list',
+            vertical: true,
+        });
         this.add_actor(this._list);
 
         this._list.connect('actor-added', this._sync.bind(this));
index 562d55636fa025817c141de0551dacb07a36a597..edb5ad14810c277b61e7e284443b6a8696432909 100644 (file)
@@ -394,13 +394,15 @@ var Notification = GObject.registerClass({
     // the title/banner. If @params.clear is %true, it will also
     // remove any additional actors/action buttons previously added.
     update(title, banner, params) {
-        params = Params.parse(params, { gicon: null,
-                                        secondaryGIcon: null,
-                                        bannerMarkup: false,
-                                        clear: false,
-                                        datetime: null,
-                                        soundName: null,
-                                        soundFile: null });
+        params = Params.parse(params, {
+            gicon: null,
+            secondaryGIcon: null,
+            bannerMarkup: false,
+            clear: false,
+            datetime: null,
+            soundName: null,
+            soundFile: null,
+        });
 
         this.title = title;
         this.bannerBodyText = banner;
@@ -561,16 +563,20 @@ var NotificationBanner = GObject.registerClass({
 
     _addSecondaryIcon() {
         if (this.notification.secondaryGIcon) {
-            let icon = new St.Icon({ gicon: this.notification.secondaryGIcon,
-                                     x_align: Clutter.ActorAlign.END });
+            const icon = new St.Icon({
+                gicon: this.notification.secondaryGIcon,
+                x_align: Clutter.ActorAlign.END,
+            });
             this.setSecondaryActor(icon);
         }
     }
 
     addButton(button, callback) {
         if (!this._buttonBox) {
-            this._buttonBox = new St.BoxLayout({ style_class: 'notification-actions',
-                                                 x_expand: true });
+            this._buttonBox = new St.BoxLayout({
+                style_class: 'notification-actions',
+                x_expand: true,
+            });
             this.setActionArea(this._buttonBox);
             global.focus_manager.add_group(this._buttonBox);
         }
@@ -596,10 +602,12 @@ var NotificationBanner = GObject.registerClass({
     }
 
     addAction(label, callback) {
-        let button = new St.Button({ style_class: 'notification-button',
-                                     label,
-                                     x_expand: true,
-                                     can_focus: true });
+        const button = new St.Button({
+            style_class: 'notification-button',
+            label,
+            x_expand: true,
+            can_focus: true,
+        });
 
         return this.addButton(button, callback);
     }
@@ -620,9 +628,11 @@ class SourceActor extends St.Widget {
         this._actorDestroyed = false;
 
         let scaleFactor = St.ThemeContext.get_for_stage(global.stage).scale_factor;
-        this._iconBin = new St.Bin({ x_expand: true,
-                                     height: size * scaleFactor,
-                                     width: size * scaleFactor });
+        this._iconBin = new St.Bin({
+            x_expand: true,
+            height: size * scaleFactor,
+            width: size * scaleFactor,
+        });
 
         this.add_actor(this._iconBin);
 
@@ -732,8 +742,10 @@ var Source = GObject.registerClass({
     // Provides a sane default implementation, override if you need
     // something more fancy.
     createIcon(size) {
-        return new St.Icon({ gicon: this.getIcon(),
-                             icon_size: size });
+        return new St.Icon({
+            gicon: this.getIcon(),
+            icon_size: size,
+        });
     }
 
     getIcon() {
@@ -836,14 +848,16 @@ var MessageTray = GObject.registerClass({
                                                   GObject.BindingFlags.SYNC_CREATE);
         this.add_constraint(constraint);
 
-        this._bannerBin = new St.Widget({ name: 'notification-container',
-                                          reactive: true,
-                                          track_hover: true,
-                                          y_align: Clutter.ActorAlign.START,
-                                          x_align: Clutter.ActorAlign.CENTER,
-                                          y_expand: true,
-                                          x_expand: true,
-                                          layout_manager: new Clutter.BinLayout() });
+        this._bannerBin = new St.Widget({
+            name: 'notification-container',
+            reactive: true,
+            track_hover: true,
+            y_align: Clutter.ActorAlign.START,
+            x_align: Clutter.ActorAlign.CENTER,
+            y_expand: true,
+            x_expand: true,
+            layout_manager: new Clutter.BinLayout(),
+        });
         this._bannerBin.connect('key-release-event',
                                 this._onNotificationKeyRelease.bind(this));
         this._bannerBin.connect('notify::hover',
index 607000b357f9dcfdb7b75694aa4764cfde31fb33..6d1d45ceb5fbcf2496c26711c62206e632fbbe30 100644 (file)
@@ -31,19 +31,22 @@ var ModalDialog = GObject.registerClass({
     Signals: { 'opened': {}, 'closed': {} },
 }, class ModalDialog extends St.Widget {
     _init(params) {
-        super._init({ visible: false,
+        super._init({
+            visible: false,
             reactive: true,
             x: 0,
             y: 0,
             accessible_role: Atk.Role.DIALOG,
         });
 
-        params = Params.parse(params, { shellReactive: false,
-                                        styleClass: null,
-                                        actionMode: Shell.ActionMode.SYSTEM_MODAL,
-                                        shouldFadeIn: true,
-                                        shouldFadeOut: true,
-                                        destroyOnClose: true });
+        params = Params.parse(params, {
+            shellReactive: false,
+            styleClass: null,
+            actionMode: Shell.ActionMode.SYSTEM_MODAL,
+            shouldFadeIn: true,
+            shouldFadeOut: true,
+            destroyOnClose: true,
+        });
 
         this._state = State.CLOSED;
         this._hasModal = false;
@@ -55,8 +58,10 @@ var ModalDialog = GObject.registerClass({
 
         Main.layoutManager.modalDialogGroup.add_actor(this);
 
-        let constraint = new Clutter.BindConstraint({ source: global.stage,
-                                                      coordinate: Clutter.BindCoordinate.ALL });
+        const constraint = new Clutter.BindConstraint({
+            source: global.stage,
+            coordinate: Clutter.BindCoordinate.ALL,
+        });
         this.add_constraint(constraint);
 
         this.backgroundStack = new St.Widget({
@@ -74,9 +79,10 @@ var ModalDialog = GObject.registerClass({
         this.buttonLayout = this.dialogLayout.buttonLayout;
 
         if (!this._shellReactive) {
-            this._lightbox = new Lightbox.Lightbox(this,
-                                                   { inhibitEvents: true,
-                                                     radialEffect: true });
+            this._lightbox = new Lightbox.Lightbox(this, {
+                inhibitEvents: true,
+                radialEffect: true,
+            });
             this._lightbox.highlight(this._backgroundBin);
 
             this._eventBlocker = new Clutter.Actor({ reactive: true });
index bf886b1a697ac36b89c6d15ab5f2be90dc234715..769c12245bd49e7292cd502410b3770899bf13e1 100644 (file)
@@ -171,13 +171,15 @@ var FdoNotificationDaemon = class FdoNotificationDaemon {
                 hints['image-data'] = hints['icon_data'];
         }
 
-        let ndata = { appName,
-                      icon,
-                      summary,
-                      body,
-                      actions,
-                      hints,
-                      timeout };
+        const ndata = {
+            appName,
+            icon,
+            summary,
+            body,
+            actions,
+            hints,
+            timeout,
+        };
         if (replacesId != 0 && this._notifications[replacesId]) {
             ndata.id = id = replacesId;
             ndata.notification = this._notifications[replacesId].notification;
@@ -458,8 +460,10 @@ class FdoNotificationDaemonSource extends MessageTray.Source {
         if (this.app) {
             return this.app.create_icon_texture(size);
         } else if (this._gicon) {
-            return new St.Icon({ gicon: this._gicon,
-                                 icon_size: size });
+            return new St.Icon({
+                gicon: this._gicon,
+                icon_size: size,
+            });
         } else {
             return null;
         }
@@ -479,15 +483,17 @@ class GtkNotificationDaemonNotification extends MessageTray.Notification {
         super._init(source);
         this._serialized = GLib.Variant.new('a{sv}', notification);
 
-        let { title,
-              body,
-              icon: gicon,
-              urgent,
-              priority,
-              buttons,
-              "default-action": defaultAction,
-              "default-action-target": defaultActionTarget,
-              timestamp: time } = notification;
+        const {
+            title,
+            body,
+            icon: gicon,
+            urgent,
+            priority,
+            buttons,
+            'default-action': defaultAction,
+            'default-action-target': defaultActionTarget,
+            timestamp: time,
+        } = notification;
 
         if (priority) {
             let urgency = PRIORITY_URGENCY_MAP[priority.unpack()];
@@ -511,9 +517,12 @@ class GtkNotificationDaemonNotification extends MessageTray.Notification {
         this._defaultAction = defaultAction?.unpack();
         this._defaultActionTarget = defaultActionTarget;
 
-        this.update(title.unpack(), body?.unpack(),
-                    { gicon: gicon ? Gio.icon_deserialize(gicon) : null,
-                      datetime: time ? GLib.DateTime.new_from_unix_local(time.unpack()) : null });
+        this.update(title.unpack(), body?.unpack(), {
+            gicon: gicon
+                ? Gio.icon_deserialize(gicon) : null,
+            datetime: time
+                ? GLib.DateTime.new_from_unix_local(time.unpack()) : null,
+        });
     }
 
     _activateAction(namespacedActionId, target) {
index b242ecca1c66817536aeb13e284c02565bc6f7da..9fdf3e88bba8c73715936eaa135880ad1c17fc35 100644 (file)
@@ -12,12 +12,16 @@ class OsdMonitorLabel extends St.Widget {
 
         this._monitor = monitor;
 
-        this._box = new St.BoxLayout({ style_class: 'osd-window',
-                                       vertical: true });
+        this._box = new St.BoxLayout({
+            style_class: 'osd-window',
+            vertical: true,
+        });
         this.add_actor(this._box);
 
-        this._label = new St.Label({ style_class: 'osd-monitor-label',
-                                     text: label });
+        this._label = new St.Label({
+            style_class: 'osd-monitor-label',
+            text: label,
+        });
         this._box.add(this._label);
 
         Main.uiGroup.add_child(this);
index bea0935729e443bcf5fb5ebde4e5cdda8fb9ea80..7fd38848bf6c203bf4e97f16889dfe92264b74db 100644 (file)
@@ -159,8 +159,10 @@ var Overview = class {
         // During transitions, we raise this to the top to avoid having the overview
         // area be reactive; it causes too many issues such as double clicks on
         // Dash elements, or mouseover handlers in the workspaces.
-        this._coverPane = new Clutter.Actor({ opacity: 0,
-                                              reactive: true });
+        this._coverPane = new Clutter.Actor({
+            opacity: 0,
+            reactive: true,
+        });
         Main.layoutManager.overviewGroup.add_child(this._coverPane);
         this._coverPane.connect('event', (_actor, event) => {
             return event.type() === Clutter.EventType.ENTER ||
@@ -329,8 +331,11 @@ var Overview = class {
             return null;
 
         let window = windows[0];
-        let clone = new Clutter.Clone({ source: window,
-                                        x: window.x, y: window.y });
+        const clone = new Clutter.Clone({
+            source: window,
+            x: window.x,
+            y: window.y,
+        });
         clone.source.connect('destroy', () => {
             clone.destroy();
         });
index 98a028f667f921117cd136c003ebf361323837af..67864026ef6293a1a768107566dd43f20a5aa90a 100644 (file)
@@ -1,8 +1,10 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 /* exported PadOsd, PadOsdService */
 
-const { Atk, Clutter, GDesktopEnums, Gio,
-        GLib, GObject, Gtk, Meta, Pango, Rsvg, St } = imports.gi;
+const {
+    Atk, Clutter, GDesktopEnums, Gio,
+    GLib, GObject, Gtk, Meta, Pango, Rsvg, St,
+} = imports.gi;
 const Signals = imports.signals;
 
 const Main = imports.ui.main;
@@ -116,19 +118,23 @@ var ActionComboBox = GObject.registerClass({
         super._init({ style_class: 'button' });
         this.set_toggle_mode(true);
 
-        let boxLayout = new Clutter.BoxLayout({ orientation: Clutter.Orientation.HORIZONTAL,
-                                                spacing: 6 });
+        const boxLayout = new Clutter.BoxLayout({
+            orientation: Clutter.Orientation.HORIZONTAL,
+            spacing: 6,
+        });
         let box = new St.Widget({ layout_manager: boxLayout });
         this.set_child(box);
 
         this._label = new St.Label({ style_class: 'combo-box-label' });
         box.add_child(this._label);
 
-        let arrow = new St.Icon({ style_class: 'popup-menu-arrow',
-                                  icon_name: 'pan-down-symbolic',
-                                  accessible_role: Atk.Role.ARROW,
-                                  y_expand: true,
-                                  y_align: Clutter.ActorAlign.CENTER });
+        const arrow = new St.Icon({
+            style_class: 'popup-menu-arrow',
+            icon_name: 'pan-down-symbolic',
+            accessible_role: Atk.Role.ARROW,
+            y_expand: true,
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         box.add_child(arrow);
 
         this._editMenu = new PopupMenu.PopupMenu(this, 0, St.Side.TOP);
@@ -195,8 +201,10 @@ var ActionEditor = GObject.registerClass({
     Signals: { 'done': {} },
 }, class ActionEditor extends St.Widget {
     _init() {
-        let boxLayout = new Clutter.BoxLayout({ orientation: Clutter.Orientation.HORIZONTAL,
-                                                spacing: 12 });
+        const boxLayout = new Clutter.BoxLayout({
+            orientation: Clutter.Orientation.HORIZONTAL,
+            spacing: 12,
+        });
 
         super._init({ layout_manager: boxLayout });
 
@@ -208,9 +216,11 @@ var ActionEditor = GObject.registerClass({
         this._keybindingEdit.connect('keybinding-edited', this._onKeybindingEdited.bind(this));
         this.add_actor(this._keybindingEdit);
 
-        this._doneButton = new St.Button({ label: _("Done"),
-                                           style_class: 'button',
-                                           x_expand: false });
+        this._doneButton = new St.Button({
+            label: _('Done'),
+            style_class: 'button',
+            x_expand: false,
+        });
         this._doneButton.connect('clicked', this._onEditingDone.bind(this));
         this.add_actor(this._doneButton);
     }
@@ -675,18 +685,24 @@ var PadOsd = GObject.registerClass({
         let constraint = new Layout.MonitorConstraint({ index: monitorIndex });
         this.add_constraint(constraint);
 
-        this._titleBox = new St.BoxLayout({ style_class: 'pad-osd-title-box',
-                                            vertical: false,
-                                            x_expand: false,
-                                            x_align: Clutter.ActorAlign.CENTER });
+        this._titleBox = new St.BoxLayout({
+            style_class: 'pad-osd-title-box',
+            vertical: false,
+            x_expand: false,
+            x_align: Clutter.ActorAlign.CENTER,
+        });
         this.add_actor(this._titleBox);
 
-        let labelBox = new St.BoxLayout({ style_class: 'pad-osd-title-menu-box',
-                                          vertical: true });
+        const labelBox = new St.BoxLayout({
+            style_class: 'pad-osd-title-menu-box',
+            vertical: true,
+        });
         this._titleBox.add_actor(labelBox);
 
-        this._titleLabel = new St.Label({ style: 'font-side: larger; font-weight: bold;',
-                                          x_align: Clutter.ActorAlign.CENTER });
+        this._titleLabel = new St.Label({
+            style: 'font-side: larger; font-weight: bold;',
+            x_align: Clutter.ActorAlign.CENTER,
+        });
         this._titleLabel.clutter_text.set_ellipsize(Pango.EllipsizeMode.NONE);
         this._titleLabel.clutter_text.set_text(padDevice.get_device_name());
         labelBox.add_actor(this._titleLabel);
@@ -699,18 +715,22 @@ var PadOsd = GObject.registerClass({
         this._actionEditor = new ActionEditor();
         this._actionEditor.connect('done', this._endActionEdition.bind(this));
 
-        this._padDiagram = new PadDiagram({ image: this._imagePath,
-                                            left_handed: settings.get_boolean('left-handed'),
-                                            editor_actor: this._actionEditor,
-                                            x_expand: true,
-                                            y_expand: true });
+        this._padDiagram = new PadDiagram({
+            image: this._imagePath,
+            left_handed: settings.get_boolean('left-handed'),
+            editor_actor: this._actionEditor,
+            x_expand: true,
+            y_expand: true,
+        });
         this.add_actor(this._padDiagram);
         this._updateActionLabels();
 
-        let buttonBox = new St.Widget({ layout_manager: new Clutter.BinLayout(),
-                                        x_expand: true,
-                                        x_align: Clutter.ActorAlign.CENTER,
-                                        y_align: Clutter.ActorAlign.CENTER });
+        const buttonBox = new St.Widget({
+            layout_manager: new Clutter.BinLayout(),
+            x_expand: true,
+            x_align: Clutter.ActorAlign.CENTER,
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this.add_actor(buttonBox);
         this._editButton = new St.Button({
             label: _('Edit…'),
index 63a31d679c22dbb326dd87566872a616392f3699..18a376cba0389c9bc5bfa19d8fb5aaf975daaaea 100644 (file)
@@ -54,11 +54,13 @@ var PageIndicators = GObject.registerClass({
         if (diff > 0) {
             for (let i = 0; i < diff; i++) {
                 let pageIndex = this._nPages + i;
-                let indicator = new St.Button({ style_class: 'page-indicator',
-                                                button_mask: St.ButtonMask.ONE |
-                                                             St.ButtonMask.TWO |
-                                                             St.ButtonMask.THREE,
-                                                reactive: this._reactive });
+                const indicator = new St.Button({
+                    style_class: 'page-indicator',
+                    button_mask: St.ButtonMask.ONE |
+                                 St.ButtonMask.TWO |
+                                 St.ButtonMask.THREE,
+                    reactive: this._reactive,
+                });
                 indicator.child = new St.Widget({
                     style_class: 'page-indicator-icon',
                     pivot_point: new Graphene.Point({ x: 0.5, y: 0.5 }),
index 78064f73f3f61b894070122a97d27fa91c366fbf..727520637c8c268c6a5401c00087137a88a82c5c 100644 (file)
@@ -66,8 +66,10 @@ var AppMenuButton = GObject.registerClass({
             iconEffect.enabled = themeNode.get_icon_style() == St.IconStyle.SYMBOLIC;
         });
 
-        this._label = new St.Label({ y_expand: true,
-                                     y_align: Clutter.ActorAlign.CENTER });
+        this._label = new St.Label({
+            y_expand: true,
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this._container.add_actor(this._label);
 
         this._visible = !Main.overview.visible;
@@ -267,8 +269,10 @@ class ActivitiesButton extends PanelMenu.Button {
 
         /* Translators: If there is no suitable word for "Activities"
            in your language, you can use the word for "Overview". */
-        this._label = new St.Label({ text: _("Activities"),
-                                     y_align: Clutter.ActorAlign.CENTER });
+        this._label = new St.Label({
+            text: _('Activities'),
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this.add_actor(this._label);
 
         this.label_actor = this._label;
@@ -474,8 +478,10 @@ const PANEL_ITEM_IMPLEMENTATIONS = {
 var Panel = GObject.registerClass(
 class Panel extends St.Widget {
     _init() {
-        super._init({ name: 'panel',
-                      reactive: true });
+        super._init({
+            name: 'panel',
+            reactive: true,
+        });
 
         this.set_offscreen_redirect(Clutter.OffscreenRedirect.ALWAYS);
 
index 5908f7a2950e8b10257960725ea6bf3a0a1fce08..81ba02ce23d8972e2da2e09b961822a58b8004dd 100644 (file)
@@ -47,11 +47,13 @@ function arrowIcon(side) {
         break;
     }
 
-    let arrow = new St.Icon({ style_class: 'popup-menu-arrow',
-                              icon_name: iconName,
-                              accessible_role: Atk.Role.ARROW,
-                              y_expand: true,
-                              y_align: Clutter.ActorAlign.CENTER });
+    const arrow = new St.Icon({
+        style_class: 'popup-menu-arrow',
+        icon_name: iconName,
+        accessible_role: Atk.Role.ARROW,
+        y_expand: true,
+        y_align: Clutter.ActorAlign.CENTER,
+    });
 
     return arrow;
 }
@@ -77,11 +79,13 @@ var PopupBaseMenuItem = GObject.registerClass({
             style_class: null,
             can_focus: true,
         });
-        super._init({ style_class: 'popup-menu-item',
-                      reactive: params.reactive,
-                      track_hover: params.reactive,
-                      can_focus: params.can_focus,
-                      accessible_role: Atk.Role.MENU_ITEM });
+        super._init({
+            style_class: 'popup-menu-item',
+            reactive: params.reactive,
+            track_hover: params.reactive,
+            can_focus: params.can_focus,
+            accessible_role: Atk.Role.MENU_ITEM,
+        });
         this._delegate = this;
 
         this._ornament = Ornament.NONE;
@@ -451,8 +455,10 @@ class PopupImageMenuItem extends PopupBaseMenuItem {
     _init(text, icon, params) {
         super._init(params);
 
-        this._icon = new St.Icon({ style_class: 'popup-menu-icon',
-                                   x_align: Clutter.ActorAlign.END });
+        this._icon = new St.Icon({
+            style_class: 'popup-menu-icon',
+            x_align: Clutter.ActorAlign.END,
+        });
         this.add_child(this._icon);
         this.label = new St.Label({
             text,
@@ -1024,9 +1030,11 @@ var PopupSubMenu = class extends PopupMenuBase {
         // Since a function of a submenu might be to provide a "More.." expander
         // with long content, we make it scrollable - the scrollbar will only take
         // effect if a CSS max-height is set on the top menu.
-        this.actor = new St.ScrollView({ style_class: 'popup-sub-menu',
-                                         hscrollbar_policy: St.PolicyType.NEVER,
-                                         vscrollbar_policy: St.PolicyType.NEVER });
+        this.actor = new St.ScrollView({
+            style_class: 'popup-sub-menu',
+            hscrollbar_policy: St.PolicyType.NEVER,
+            vscrollbar_policy: St.PolicyType.NEVER,
+        });
 
         this.actor.add_actor(this.box);
         this.actor._delegate = this;
@@ -1194,9 +1202,11 @@ class PopupSubMenuMenuItem extends PopupBaseMenuItem {
             this.add_child(this.icon);
         }
 
-        this.label = new St.Label({ text,
-                                    y_expand: true,
-                                    y_align: Clutter.ActorAlign.CENTER });
+        this.label = new St.Label({
+            text,
+            y_expand: true,
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this.add_child(this.label);
         this.label_actor = this.label;
 
@@ -1209,8 +1219,10 @@ class PopupSubMenuMenuItem extends PopupBaseMenuItem {
         this._triangle = arrowIcon(St.Side.RIGHT);
         this._triangle.pivot_point = new Graphene.Point({ x: 0.5, y: 0.6 });
 
-        this._triangleBin = new St.Widget({ y_expand: true,
-                                            y_align: Clutter.ActorAlign.CENTER });
+        this._triangleBin = new St.Widget({
+            y_expand: true,
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this._triangleBin.add_child(this._triangle);
 
         this.add_child(this._triangleBin);
index a31a17ff527d6c5de2fbff8dc49e16d0e827c60a..8ebb5505209dcde1f26b2640e10b77bc175f5855 100644 (file)
@@ -198,12 +198,14 @@ var RemoteSearchProvider = class {
         else
             gFlags |= Gio.DBusProxyFlags.DO_NOT_AUTO_START;
 
-        this.proxy = new Gio.DBusProxy({ g_bus_type: Gio.BusType.SESSION,
-                                         g_name: dbusName,
-                                         g_object_path: dbusPath,
-                                         g_interface_info: proxyInfo,
-                                         g_interface_name: proxyInfo.name,
-                                         gFlags });
+        this.proxy = new Gio.DBusProxy({
+            g_bus_type: Gio.BusType.SESSION,
+            g_name: dbusName,
+            g_object_path: dbusPath,
+            g_interface_info: proxyInfo,
+            g_interface_name: proxyInfo.name,
+            gFlags,
+        });
         this.proxy.init_async(GLib.PRIORITY_DEFAULT, null);
 
         this.appInfo = appInfo;
@@ -289,13 +291,13 @@ var RemoteSearchProvider = class {
                     metas[i][prop] = metas[i][prop].deep_unpack();
             }
 
-            resultMetas.push({ id: metas[i]['id'],
-                               name: metas[i]['name'],
-                               description: metas[i]['description'],
-                               createIcon: size => {
-                                   return this.createIcon(size, metas[i]);
-                               },
-                               clipboardText: metas[i]['clipboardText'] });
+            resultMetas.push({
+                id: metas[i]['id'],
+                name: metas[i]['name'],
+                description: metas[i]['description'],
+                createIcon: size => this.createIcon(size, metas[i]),
+                clipboardText: metas[i]['clipboardText'],
+            });
         }
         callback(resultMetas);
     }
index f38062228fb1e5c54277fb7005ca50b46bbfb406..20ca9ed9f6808e33ee06b2d6b7935a1580335faf 100644 (file)
@@ -12,25 +12,31 @@ var Ripples = class Ripples {
         this._px = px;
         this._py = py;
 
-        this._ripple1 = new St.BoxLayout({ style_class: styleClass,
-                                           opacity: 0,
-                                           can_focus: false,
-                                           reactive: false,
-                                           visible: false });
+        this._ripple1 = new St.BoxLayout({
+            style_class: styleClass,
+            opacity: 0,
+            can_focus: false,
+            reactive: false,
+            visible: false,
+        });
         this._ripple1.set_pivot_point(px, py);
 
-        this._ripple2 = new St.BoxLayout({ style_class: styleClass,
-                                           opacity: 0,
-                                           can_focus: false,
-                                           reactive: false,
-                                           visible: false });
+        this._ripple2 = new St.BoxLayout({
+            style_class: styleClass,
+            opacity: 0,
+            can_focus: false,
+            reactive: false,
+            visible: false,
+        });
         this._ripple2.set_pivot_point(px, py);
 
-        this._ripple3 = new St.BoxLayout({ style_class: styleClass,
-                                           opacity: 0,
-                                           can_focus: false,
-                                           reactive: false,
-                                           visible: false });
+        this._ripple3 = new St.BoxLayout({
+            style_class: styleClass,
+            opacity: 0,
+            can_focus: false,
+            reactive: false,
+            visible: false,
+        });
         this._ripple3.set_pivot_point(px, py);
     }
 
index bf4bf04a8c659765eeaf8d4c4875ae0494934642..a78172047e499478f3d19d5b825de03520eb1f4b 100644 (file)
@@ -1,7 +1,9 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 
-const { AccountsService, Clutter, Gio,
-        GLib, Graphene, Meta, Shell, St } = imports.gi;
+const {
+    AccountsService, Clutter, Gio,
+    GLib, Graphene, Meta, Shell, St,
+} = imports.gi;
 const Signals = imports.signals;
 
 const GnomeSession = imports.misc.gnomeSession;
@@ -130,13 +132,15 @@ var ScreenShield = class {
         // The "long" lightbox is used for the longer (20 seconds) fade from session
         // to idle status, the "short" is used for quickly fading to black when locking
         // manually
-        this._longLightbox = new Lightbox.Lightbox(Main.uiGroup,
-                                                   { inhibitEvents: true,
-                                                     fadeFactor: 1 });
+        this._longLightbox = new Lightbox.Lightbox(Main.uiGroup, {
+            inhibitEvents: true,
+            fadeFactor: 1,
+        });
         this._longLightbox.connect('notify::active', this._onLongLightbox.bind(this));
-        this._shortLightbox = new Lightbox.Lightbox(Main.uiGroup,
-                                                    { inhibitEvents: true,
-                                                      fadeFactor: 1 });
+        this._shortLightbox = new Lightbox.Lightbox(Main.uiGroup, {
+            inhibitEvents: true,
+            fadeFactor: 1,
+        });
         this._shortLightbox.connect('notify::active', this._onShortLightbox.bind(this));
 
         this.idleMonitor = global.backend.get_core_idle_monitor();
@@ -440,8 +444,10 @@ var ScreenShield = class {
     }
 
     _onUnlockFailed() {
-        this._resetLockScreen({ animateLockScreen: true,
-                                fadeToBlack: false });
+        this._resetLockScreen({
+            animateLockScreen: true,
+            fadeToBlack: false,
+        });
     }
 
     _resetLockScreen(params) {
@@ -606,8 +612,10 @@ var ScreenShield = class {
                 Main.sessionMode.pushMode('unlock-dialog');
         }
 
-        this._resetLockScreen({ animateLockScreen: animate,
-                                fadeToBlack: true });
+        this._resetLockScreen({
+            animateLockScreen: animate,
+            fadeToBlack: true,
+        });
         // On wayland, a crash brings down the entire session, so we don't
         // need to defend against being restarted unlocked
         if (!Meta.is_wayland_compositor())
index d40c5b2449e8fa58aee7c543065f1033d9d69920..63069d21627b4a0bf212e4a3fc121404283872fa 100644 (file)
@@ -2542,8 +2542,10 @@ class SelectArea extends St.Widget {
 
         this._grabHelper = new GrabHelper.GrabHelper(this);
 
-        let constraint = new Clutter.BindConstraint({ source: global.stage,
-                                                      coordinate: Clutter.BindCoordinate.ALL });
+        const constraint = new Clutter.BindConstraint({
+            source: global.stage,
+            coordinate: Clutter.BindCoordinate.ALL,
+        });
         this.add_constraint(constraint);
 
         this._rubberband = new St.Widget({
@@ -2768,8 +2770,10 @@ class PickPixel extends St.Widget {
 
         this._grabHelper = new GrabHelper.GrabHelper(this);
 
-        let constraint = new Clutter.BindConstraint({ source: global.stage,
-                                                      coordinate: Clutter.BindCoordinate.ALL });
+        const constraint = new Clutter.BindConstraint({
+            source: global.stage,
+            coordinate: Clutter.BindCoordinate.ALL,
+        });
         this.add_constraint(constraint);
 
         const action = new Clutter.ClickAction();
index 3601130760e029f5ecfd6078e683954d4a8fa621..67a2652d135ab272a2eb67b4018237ed493aaf7a 100644 (file)
@@ -112,11 +112,13 @@ function _callRemote(obj, method, ...args) {
  * until the window has been mapped and exposed, use waitTestWindows().
  */
 function createTestWindow(params) {
-    params = Params.parse(params, { width: 640,
-                                    height: 480,
-                                    alpha: false,
-                                    maximized: false,
-                                    redraws: false });
+    params = Params.parse(params, {
+        width: 640,
+        height: 480,
+        alpha: false,
+        maximized: false,
+        redraws: false,
+    });
 
     let perfHelper = _getPerfHelper();
     return _callRemote(perfHelper, perfHelper.CreateWindowRemote,
index 1e8aeb6c70de345752ccd1a94bcb6ac5dde16ad9..cd5474db30329803add75b2012b7fa56e66a2625 100644 (file)
@@ -912,19 +912,27 @@ class ProviderInfo extends St.Button {
             y_align: Clutter.ActorAlign.START,
         });
 
-        this._content = new St.BoxLayout({ vertical: false,
-                                           style_class: 'list-search-provider-content' });
+        this._content = new St.BoxLayout({
+            vertical: false,
+            style_class: 'list-search-provider-content',
+        });
         this.set_child(this._content);
 
-        let icon = new St.Icon({ icon_size: this.PROVIDER_ICON_SIZE,
-                                 gicon: provider.appInfo.get_icon() });
+        const icon = new St.Icon({
+            icon_size: this.PROVIDER_ICON_SIZE,
+            gicon: provider.appInfo.get_icon(),
+        });
 
-        let detailsBox = new St.BoxLayout({ style_class: 'list-search-provider-details',
-                                            vertical: true,
-                                            x_expand: true });
+        const detailsBox = new St.BoxLayout({
+            style_class: 'list-search-provider-details',
+            vertical: true,
+            x_expand: true,
+        });
 
-        let nameLabel = new St.Label({ text: provider.appInfo.get_name(),
-                                       x_align: Clutter.ActorAlign.START });
+        const nameLabel = new St.Label({
+            text: provider.appInfo.get_name(),
+            x_align: Clutter.ActorAlign.START,
+        });
 
         this._moreLabel = new St.Label({ x_align: Clutter.ActorAlign.START });
 
index 9f1e75d02bbbce439a4f297c14432327c0435d00..8faa112eaf6ccbf31f400a20aaffa0ad8d6dc016 100644 (file)
@@ -117,11 +117,13 @@ var GnomeShell = class {
         for (let param in params)
             params[param] = params[param].deep_unpack();
 
-        let { connector,
-              label,
-              level,
-              max_level: maxLevel,
-              icon: serializedIcon } = params;
+        const {
+            connector,
+            label,
+            level,
+            max_level: maxLevel,
+            icon: serializedIcon,
+        } = params;
 
         let monitorIndex = -1;
         if (connector) {
index 17247880f5d4642ab083b989135345db426f53ea..aa60206603ee4af049dae38c2f1e5952afd4950e 100644 (file)
@@ -38,8 +38,10 @@ class Indicator extends PanelMenu.SystemIndicator {
             this._sliderChanged.bind(this));
         this._slider.accessible_name = _("Brightness");
 
-        let icon = new St.Icon({ icon_name: 'display-brightness-symbolic',
-                                 style_class: 'popup-menu-icon' });
+        const icon = new St.Icon({
+            icon_name: 'display-brightness-symbolic',
+            style_class: 'popup-menu-icon',
+        });
         this._item.add(icon);
         this._item.add_child(this._slider);
         this._item.connect('button-press-event', (actor, event) => {
index d82a465037f55052fcf8f920a0334a25c90b3c8f..82726e5b68881122ed8fc38e77e6432926265b2f 100644 (file)
@@ -35,8 +35,10 @@ class DwellClickIndicator extends PanelMenu.Button {
     _init() {
         super._init(0.5, _("Dwell Click"));
 
-        this._icon = new St.Icon({ style_class: 'system-status-icon',
-                                   icon_name: 'pointer-primary-click-symbolic' });
+        this._icon = new St.Icon({
+            style_class: 'system-status-icon',
+            icon_name: 'pointer-primary-click-symbolic',
+        });
         this.add_child(this._icon);
 
         this._a11ySettings = new Gio.Settings({ schema_id: MOUSE_A11Y_SCHEMA });
index c2b5cfd6ee5555777d031d0731ea25a602a80106..f7527313c864cbcfbab661625cb9fe2c1bfb64b8 100644 (file)
@@ -892,8 +892,10 @@ class InputSourceIndicator extends PanelMenu.Button {
             let menuItem = new LayoutMenuItem(is.displayName, is.shortName);
             menuItem.connect('activate', () => is.activate(true));
 
-            let indicatorLabel = new St.Label({ text: is.shortName,
-                                                visible: false });
+            const indicatorLabel = new St.Label({
+                text: is.shortName,
+                visible: false,
+            });
 
             this._menuItems[i] = menuItem;
             this._indicatorLabels[i] = indicatorLabel;
index 7f00292181fa2751c351c4799e02b5d8fb2fb9a7..f213d80821c24bb2190964371b9d3cb45acefdd8 100644 (file)
@@ -413,11 +413,15 @@ var GeolocationDialog = GObject.registerClass({
 
         this.contentLayout.add_child(content);
 
-        let button = this.addButton({ label: _("Deny Access"),
-                                      action: this._onDenyClicked.bind(this),
-                                      key: Clutter.KEY_Escape });
-        this.addButton({ label: _("Grant Access"),
-                         action: this._onGrantClicked.bind(this) });
+        const button = this.addButton({
+            label: _('Deny Access'),
+            action: this._onDenyClicked.bind(this),
+            key: Clutter.KEY_Escape,
+        });
+        this.addButton({
+            label: _('Grant Access'),
+            action: this._onGrantClicked.bind(this),
+        });
 
         this.setInitialKeyFocus(button);
     }
index f06a8fe822ddeeacbd54df5dfd2d7cc7e1f2fca8..4b88be547b18a655d450dc61f745bbfcad9f942e 100644 (file)
@@ -700,9 +700,11 @@ var NMWirelessDialogItem = GObject.registerClass({
         this._network = network;
         this._ap = network.accessPoints[0];
 
-        super._init({ style_class: 'nm-dialog-item',
-                      can_focus: true,
-                      reactive: true });
+        super._init({
+            style_class: 'nm-dialog-item',
+            can_focus: true,
+            reactive: true,
+        });
 
         let action = new Clutter.ClickAction();
         action.connect('clicked', () => this.grab_key_focus());
@@ -717,8 +719,10 @@ var NMWirelessDialogItem = GObject.registerClass({
         this.label_actor = this._label;
         this.add_child(this._label);
 
-        this._selectedIcon = new St.Icon({ style_class: 'nm-dialog-icon',
-                                           icon_name: 'object-select-symbolic' });
+        this._selectedIcon = new St.Icon({
+            style_class: 'nm-dialog-icon',
+            icon_name: 'object-select-symbolic',
+        });
         this.add(this._selectedIcon);
 
         this._icons = new St.BoxLayout({
@@ -913,14 +917,20 @@ class NMWirelessDialog extends ModalDialog.ModalDialog {
     _buildLayout() {
         let headline = new St.BoxLayout({ style_class: 'nm-dialog-header-hbox' });
 
-        let icon = new St.Icon({ style_class: 'nm-dialog-header-icon',
-                                 icon_name: 'network-wireless-signal-excellent-symbolic' });
+        const icon = new St.Icon({
+            style_class: 'nm-dialog-header-icon',
+            icon_name: 'network-wireless-signal-excellent-symbolic',
+        });
 
         let titleBox = new St.BoxLayout({ vertical: true });
-        let title = new St.Label({ style_class: 'nm-dialog-header',
-                                   text: _("Wi-Fi Networks") });
-        let subtitle = new St.Label({ style_class: 'nm-dialog-subheader',
-                                      text: _("Select a network") });
+        const title = new St.Label({
+            style_class: 'nm-dialog-header',
+            text: _('Wi-Fi Networks'),
+        });
+        const subtitle = new St.Label({
+            style_class: 'nm-dialog-subheader',
+            text: _('Select a network'),
+        });
         titleBox.add(title);
         titleBox.add(subtitle);
 
@@ -944,21 +954,27 @@ class NMWirelessDialog extends ModalDialog.ModalDialog {
         this._scrollView.add_actor(this._itemBox);
         this._stack.add_child(this._scrollView);
 
-        this._noNetworksBox = new St.BoxLayout({ vertical: true,
-                                                 style_class: 'no-networks-box',
-                                                 x_align: Clutter.ActorAlign.CENTER,
-                                                 y_align: Clutter.ActorAlign.CENTER });
+        this._noNetworksBox = new St.BoxLayout({
+            vertical: true,
+            style_class: 'no-networks-box',
+            x_align: Clutter.ActorAlign.CENTER,
+            y_align: Clutter.ActorAlign.CENTER,
+        });
 
         this._noNetworksSpinner = new Animation.Spinner(16);
         this._noNetworksBox.add_actor(this._noNetworksSpinner);
-        this._noNetworksBox.add_actor(new St.Label({ style_class: 'no-networks-label',
-                                                     text: _("No Networks") }));
+        this._noNetworksBox.add_actor(new St.Label({
+            style_class: 'no-networks-label',
+            text: _('No Networks'),
+        }));
         this._stack.add_child(this._noNetworksBox);
 
-        this._airplaneBox = new St.BoxLayout({ vertical: true,
-                                               style_class: 'nm-dialog-airplane-box',
-                                               x_align: Clutter.ActorAlign.CENTER,
-                                               y_align: Clutter.ActorAlign.CENTER });
+        this._airplaneBox = new St.BoxLayout({
+            vertical: true,
+            style_class: 'nm-dialog-airplane-box',
+            x_align: Clutter.ActorAlign.CENTER,
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this._airplaneIcon = new St.Icon({ icon_size: 48 });
         this._airplaneHeadline = new St.Label({ style_class: 'nm-dialog-airplane-headline headline' });
         this._airplaneText = new St.Label({ style_class: 'nm-dialog-airplane-text' });
@@ -972,8 +988,10 @@ class NMWirelessDialog extends ModalDialog.ModalDialog {
                 this._client.wireless_enabled = true;
         });
         airplaneSubStack.add_actor(this._airplaneButton);
-        this._airplaneInactive = new St.Label({ style_class: 'nm-dialog-airplane-text',
-                                                text: _("Use hardware switch to turn off") });
+        this._airplaneInactive = new St.Label({
+            style_class: 'nm-dialog-airplane-text',
+            text: _('Use hardware switch to turn off'),
+        });
         airplaneSubStack.add_actor(this._airplaneInactive);
 
         this._airplaneBox.add_child(this._airplaneIcon);
@@ -984,12 +1002,16 @@ class NMWirelessDialog extends ModalDialog.ModalDialog {
 
         this.contentLayout.add_child(this._stack);
 
-        this._disconnectButton = this.addButton({ action: () => this.close(),
-                                                  label: _("Cancel"),
-                                                  key: Clutter.KEY_Escape });
-        this._connectButton = this.addButton({ action: this._connect.bind(this),
-                                               label: _("Connect"),
-                                               key: Clutter.KEY_Return });
+        this._disconnectButton = this.addButton({
+            action: () => this.close(),
+            label: _('Cancel'),
+            key: Clutter.KEY_Escape,
+        });
+        this._connectButton = this.addButton({
+            action: this._connect.bind(this),
+            label: _('Connect'),
+            key: Clutter.KEY_Return,
+        });
     }
 
     _connect() {
index 2d9b0deadf77818fa9dc2c5b6975071d9485da3e..7338582188325e4c4b88367fe8bb7dfa44ea165f 100644 (file)
@@ -100,11 +100,15 @@ class SwitchMonitorSwitcher extends SwitcherPopup.SwitcherList {
     }
 
     _addIcon(item) {
-        let box = new St.BoxLayout({ style_class: 'alt-tab-app',
-                                     vertical: true });
+        const box = new St.BoxLayout({
+            style_class: 'alt-tab-app',
+            vertical: true,
+        });
 
-        let icon = new St.Icon({ icon_name: item.icon,
-                                 icon_size: APP_ICON_SIZE });
+        const icon = new St.Icon({
+            icon_name: item.icon,
+            icon_size: APP_ICON_SIZE,
+        });
         box.add_child(icon);
 
         let text = new St.Label({
index 17c3fcaa3e293fa9875ca88cb6530bdc1e09a39a..a380c861a30a0aee00b1b411cc198d73e3084399 100644 (file)
@@ -33,9 +33,11 @@ var SwitcherPopup = GObject.registerClass({
     GTypeFlags: GObject.TypeFlags.ABSTRACT,
 }, class SwitcherPopup extends St.Widget {
     _init(items) {
-        super._init({ style_class: 'switcher-popup',
-                      reactive: true,
-                      visible: false });
+        super._init({
+            style_class: 'switcher-popup',
+            reactive: true,
+            visible: false,
+        });
 
         this._switcherList = null;
 
@@ -359,8 +361,10 @@ var SwitcherPopup = GObject.registerClass({
 var SwitcherButton = GObject.registerClass(
 class SwitcherButton extends St.Button {
     _init(square) {
-        super._init({ style_class: 'item-box',
-                      reactive: true });
+        super._init({
+            style_class: 'item-box',
+            reactive: true,
+        });
 
         this._square = square;
     }
@@ -374,17 +378,21 @@ class SwitcherButton extends St.Button {
 });
 
 var SwitcherList = GObject.registerClass({
-    Signals: { 'item-activated': { param_types: [GObject.TYPE_INT] },
-               'item-entered': { param_types: [GObject.TYPE_INT] },
-               'item-removed': { param_types: [GObject.TYPE_INT] } },
+    Signals: {
+        'item-activated': { param_types: [GObject.TYPE_INT] },
+        'item-entered': { param_types: [GObject.TYPE_INT] },
+        'item-removed': { param_types: [GObject.TYPE_INT] },
+    },
 }, class SwitcherList extends St.Widget {
     _init(squareItems) {
         super._init({ style_class: 'switcher-list' });
 
-        this._list = new St.BoxLayout({ style_class: 'switcher-list-item-container',
-                                        vertical: false,
-                                        x_expand: true,
-                                        y_expand: true });
+        this._list = new St.BoxLayout({
+            style_class: 'switcher-list-item-container',
+            vertical: false,
+            x_expand: true,
+            y_expand: true,
+        });
 
         let layoutManager = this._list.get_layout_manager();
 
@@ -393,21 +401,27 @@ var SwitcherList = GObject.registerClass({
             this._list.spacing = this._list.get_theme_node().get_length('spacing');
         });
 
-        this._scrollView = new St.ScrollView({ style_class: 'hfade',
-                                               enable_mouse_scrolling: false });
+        this._scrollView = new St.ScrollView({
+            style_class: 'hfade',
+            enable_mouse_scrolling: false,
+        });
         this._scrollView.set_policy(St.PolicyType.NEVER, St.PolicyType.NEVER);
 
         this._scrollView.add_actor(this._list);
         this.add_actor(this._scrollView);
 
         // Those arrows indicate whether scrolling in one direction is possible
-        this._leftArrow = new St.DrawingArea({ style_class: 'switcher-arrow',
-                                               pseudo_class: 'highlighted' });
+        this._leftArrow = new St.DrawingArea({
+            style_class: 'switcher-arrow',
+            pseudo_class: 'highlighted',
+        });
         this._leftArrow.connect('repaint', () => {
             drawArrow(this._leftArrow, St.Side.LEFT);
         });
-        this._rightArrow = new St.DrawingArea({ style_class: 'switcher-arrow',
-                                                pseudo_class: 'highlighted' });
+        this._rightArrow = new St.DrawingArea({
+            style_class: 'switcher-arrow',
+            pseudo_class: 'highlighted',
+        });
         this._rightArrow.connect('repaint', () => {
             drawArrow(this._rightArrow, St.Side.RIGHT);
         });
index 990b1c02faa004541e9e5c2a6067a64e9f46cbe4..61e277540a9fc87572c8e697f0ffd0f20cb5d92c 100644 (file)
@@ -1,8 +1,10 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 /* exported UnlockDialog */
 
-const { AccountsService, Atk, Clutter, Gdm, Gio,
-        GnomeDesktop, GLib, GObject, Meta, Shell, St } = imports.gi;
+const {
+    AccountsService, Atk, Clutter, Gdm, Gio,
+    GnomeDesktop, GLib, GObject, Meta, Shell, St,
+} = imports.gi;
 
 const Background = imports.ui.background;
 const Layout = imports.ui.layout;
index c376028af307f63f70fa3f9751d1c1717545905f..aa1de12543ac82775996d1e24865074d199a5769 100644 (file)
@@ -111,12 +111,16 @@ class UserWidgetLabel extends St.Widget {
 
         this._user = user;
 
-        this._realNameLabel = new St.Label({ style_class: 'user-widget-label',
-                                             y_align: Clutter.ActorAlign.CENTER });
+        this._realNameLabel = new St.Label({
+            style_class: 'user-widget-label',
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this.add_child(this._realNameLabel);
 
-        this._userNameLabel = new St.Label({ style_class: 'user-widget-label',
-                                             y_align: Clutter.ActorAlign.CENTER });
+        this._userNameLabel = new St.Label({
+            style_class: 'user-widget-label',
+            y_align: Clutter.ActorAlign.CENTER,
+        });
         this.add_child(this._userNameLabel);
 
         this._currentLabel = null;
index fd38fd262951ec11f12d9dc068e2e40506966175..63c6d9061cce267ebae626af667e0ed836c03d94 100644 (file)
@@ -42,13 +42,15 @@ class WelcomeDialog extends ModalDialog.ModalDialog {
 
         this.contentLayout.add_child(content);
 
-        this.addButton({ label: _('No Thanks'),
-            action: () => {
-                this._sendResponse(DialogResponse.NO_THANKS);
-            },
-            key: Clutter.KEY_Escape });
-        this.addButton({ label: _('Take Tour'),
-            action: () => this._sendResponse(DialogResponse.TAKE_TOUR) });
+        this.addButton({
+            label: _('No Thanks'),
+            action: () => this._sendResponse(DialogResponse.NO_THANKS),
+            key: Clutter.KEY_Escape,
+        });
+        this.addButton({
+            label: _('Take Tour'),
+            action: () => this._sendResponse(DialogResponse.TAKE_TOUR),
+        });
     }
 
     _sendResponse(response) {
index 0f56082303533ee2cd60e2def96f25a4ef27402e..de8e4cec1433e7d08e048192d398eb076598adc8 100644 (file)
@@ -68,12 +68,16 @@ class DisplayChangeDialog extends ModalDialog.ModalDialog {
         /* Translators: this and the following message should be limited in length,
            to avoid ellipsizing the labels.
         */
-        this._cancelButton = this.addButton({ label: _("Revert Settings"),
-                                              action: this._onFailure.bind(this),
-                                              key: Clutter.KEY_Escape });
-        this._okButton = this.addButton({ label: _("Keep Changes"),
-                                          action: this._onSuccess.bind(this),
-                                          default: true });
+        this._cancelButton = this.addButton({
+            label: _('Revert Settings'),
+            action: this._onFailure.bind(this),
+            key: Clutter.KEY_Escape,
+        });
+        this._okButton = this.addButton({
+            label: _('Keep Changes'),
+            action: this._onSuccess.bind(this),
+            default: true,
+        });
 
         this._timeoutId = GLib.timeout_add(GLib.PRIORITY_DEFAULT, ONE_SECOND, this._tick.bind(this));
         GLib.Source.set_name_by_id(this._timeoutId, '[gnome-shell] this._tick');
@@ -413,10 +417,12 @@ class TilePreview extends St.Widget {
         this._updateStyle(monitor);
 
         if (!this._showing || changeMonitor) {
-            let monitorRect = new Meta.Rectangle({ x: monitor.x,
-                                                   y: monitor.y,
-                                                   width: monitor.width,
-                                                   height: monitor.height });
+            const monitorRect = new Meta.Rectangle({
+                x: monitor.x,
+                y: monitor.y,
+                width: monitor.width,
+                height: monitor.height,
+            });
             let [, rect] = window.get_frame_rect().intersect(monitorRect);
             this.set_size(rect.width, rect.height);
             this.set_position(rect.x, rect.y);
@@ -533,10 +539,13 @@ var ResizePopup = GObject.registerClass(
 class ResizePopup extends St.Widget {
     _init() {
         super._init({ layout_manager: new Clutter.BinLayout() });
-        this._label = new St.Label({ style_class: 'resize-popup',
-                                     x_align: Clutter.ActorAlign.CENTER,
-                                     y_align: Clutter.ActorAlign.CENTER,
-                                     x_expand: true, y_expand: true });
+        this._label = new St.Label({
+            style_class: 'resize-popup',
+            x_align: Clutter.ActorAlign.CENTER,
+            y_align: Clutter.ActorAlign.CENTER,
+            x_expand: true,
+            y_expand: true,
+        });
         this.add_child(this._label);
         Main.uiGroup.add_actor(this);
     }
index e67ec9ec0ff984828253708abd55fe687657929e..16bda2a7fff07e6c9ffabb16151ceab07f258e3a 100644 (file)
@@ -1,8 +1,9 @@
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
 /* exported WindowPreview */
 
-const { Atk, Clutter, GLib, GObject,
-        Graphene, Meta, Pango, Shell, St } = imports.gi;
+const {
+    Atk, Clutter, GLib, GObject, Graphene, Meta, Pango, Shell, St,
+} = imports.gi;
 
 const DND = imports.ui.dnd;
 const OverviewControls = imports.ui.overviewControls;
@@ -104,11 +105,12 @@ var WindowPreview = GObject.registerClass({
         this.add_action(clickAction);
         this.connect('destroy', this._onDestroy.bind(this));
 
-        this._draggable = DND.makeDraggable(this,
-                                            { restoreOnSuccess: true,
-                                              manualMode: true,
-                                              dragActorMaxSize: WINDOW_DND_SIZE,
-                                              dragActorOpacity: DRAGGING_WINDOW_OPACITY });
+        this._draggable = DND.makeDraggable(this, {
+            restoreOnSuccess: true,
+            manualMode: true,
+            dragActorMaxSize: WINDOW_DND_SIZE,
+            dragActorOpacity: DRAGGING_WINDOW_OPACITY,
+        });
         this._draggable.connect('drag-begin', this._onDragBegin.bind(this));
         this._draggable.connect('drag-cancelled', this._onDragCancelled.bind(this));
         this._draggable.connect('drag-end', this._onDragEnd.bind(this));
index 1ad403f9f82b996d174c584f143dcd089c8272ca..bba56f92676b9aac6314169846afbc452b5c0fa2 100644 (file)
@@ -152,10 +152,12 @@ var UnalignedLayoutStrategy = class extends LayoutStrategy {
         //   meant to be scaled
         //
         // * neither height/fullHeight have any sort of spacing or padding
-        return { x: 0, y: 0,
-                 width: 0, height: 0,
-                 fullWidth: 0, fullHeight: 0,
-                 windows: [] };
+        return {
+            x: 0, y: 0,
+            width: 0, height: 0,
+            fullWidth: 0, fullHeight: 0,
+            windows: [],
+        };
     }
 
     // Computes and returns an individual scaling factor for @window,
@@ -1499,8 +1501,10 @@ class Workspace extends St.Widget {
         } else if (!source.app && source.shellWorkspaceLaunch) {
             // While unused in our own drag sources, shellWorkspaceLaunch allows
             // extensions to define custom actions for their drag sources.
-            source.shellWorkspaceLaunch({ workspace: workspaceIndex,
-                                          timestamp: time });
+            source.shellWorkspaceLaunch({
+                workspace: workspaceIndex,
+                timestamp: time,
+            });
             return true;
         }
 
index 412527c93819fd655721f1e1b32969de33da8916..69fc7c5bd29d4e77308d117bded83ee259df7064 100644 (file)
@@ -76,10 +76,11 @@ var WindowClone = GObject.registerClass({
 
         this.connect('destroy', this._onDestroy.bind(this));
 
-        this._draggable = DND.makeDraggable(this,
-                                            { restoreOnSuccess: true,
-                                              dragActorMaxSize: Workspace.WINDOW_DND_SIZE,
-                                              dragActorOpacity: Workspace.DRAGGING_WINDOW_OPACITY });
+        this._draggable = DND.makeDraggable(this, {
+            restoreOnSuccess: true,
+            dragActorMaxSize: Workspace.WINDOW_DND_SIZE,
+            dragActorOpacity: Workspace.DRAGGING_WINDOW_OPACITY,
+        });
         this._draggable.connect('drag-begin', this._onDragBegin.bind(this));
         this._draggable.connect('drag-cancelled', this._onDragCancelled.bind(this));
         this._draggable.connect('drag-end', this._onDragEnd.bind(this));
@@ -593,8 +594,10 @@ var WorkspaceThumbnail = GObject.registerClass({
         } else if (!source.app && source.shellWorkspaceLaunch) {
             // While unused in our own drag sources, shellWorkspaceLaunch allows
             // extensions to define custom actions for their drag sources.
-            source.shellWorkspaceLaunch({ workspace: this.metaWorkspace.index(),
-                                          timestamp: time });
+            source.shellWorkspaceLaunch({
+                workspace: this.metaWorkspace.index(),
+                timestamp: time,
+            });
             return true;
         }
 
@@ -964,8 +967,10 @@ var ThumbnailsBox = GObject.registerClass({
             } else if (!source.app && source.shellWorkspaceLaunch) {
                 // While unused in our own drag sources, shellWorkspaceLaunch allows
                 // extensions to define custom actions for their drag sources.
-                source.shellWorkspaceLaunch({ workspace: newWorkspaceIndex,
-                                              timestamp: time });
+                source.shellWorkspaceLaunch({
+                    workspace: newWorkspaceIndex,
+                    timestamp: time,
+                });
             }
 
             if (source.app || (!source.app && source.shellWorkspaceLaunch)) {
index 95549f3dbb33fab38dd0e12063de6195fff6aacc..0ea81a397bdc253cbadaa575b2dbdac4a7fd424d 100644 (file)
@@ -59,8 +59,10 @@ var XdndHandler = class {
             if (!cursorWindow.get_meta_window().is_override_redirect())
                 return;
 
-            let constraintPosition = new Clutter.BindConstraint({ coordinate: Clutter.BindCoordinate.POSITION,
-                                                                  source: cursorWindow });
+            const constraintPosition = new Clutter.BindConstraint({
+                coordinate: Clutter.BindCoordinate.POSITION,
+                source: cursorWindow,
+            });
 
             this._cursorWindowClone = new Clutter.Clone({ source: cursorWindow });
             Main.uiGroup.add_actor(this._cursorWindowClone);
index 127166ef2c54b05b91310998d8f29bfeb0bba811..9e5e6dcefc59ac61c86f2ffd2fcfce926329e17a 100644 (file)
@@ -7,8 +7,6 @@ rules:
       - 'CallExpression[callee.object.name=GObject][callee.property.name=registerClass] > ClassExpression:first-child'
       CallExpression:
         arguments: first
-      ObjectExpression: first
-      MemberExpression: off
   jsdoc/check-alignment: off
   jsdoc/check-param-names: off
   jsdoc/check-tag-names: off
@@ -20,7 +18,4 @@ rules:
   jsdoc/require-param-description: off
   jsdoc/require-param-name: off
   jsdoc/require-param-type: off
-  object-curly-newline:
-    - error
-    - consistent: true
   quotes: off